# Help with apache reverse proxy to get SSL for my Owncast stream server

**URL:** <https://community.letsencrypt.org/t/help-with-apache-reverse-proxy-to-get-ssl-for-my-owncast-stream-server/175942>\
**Category:** Help\
**Created:** [April 16, 2022, 1:50am UTC](https://community.letsencrypt.org/t/help-with-apache-reverse-proxy-to-get-ssl-for-my-owncast-stream-server/175942 "2022-04-16T01:50:59Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![pastlife](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/pastlife/32/82303_2.png) [@pastlife](https://community.letsencrypt.org/u/pastlife)\
**Post date:** [April 16, 2022, 7:59am UTC](https://community.letsencrypt.org/t/help-with-apache-reverse-proxy-to-get-ssl-for-my-owncast-stream-server/175942/3 "2022-04-16T07:59:24Z")

</div>

I succeeded on steps 1-3  
[https://live.pastlife.works/](https://live.pastlife.works/) is up with a simple page

I'm not sure how to edit the example from Owncast's docs

## le-ssl.conf for my subdomain looks like this:

```nohighlight
<IfModule mod_ssl.c>
<VirtualHost *:443>
	ServerName live.pastlife.works
	ServerAdmin email
        ServerAlias live.pastlife.works	
	DocumentRoot /var/www/live.pastlife.works
		
	ErrorLog ${APACHE_LOG_DIR}/error.log
	CustomLog ${APACHE_LOG_DIR}/access.log combined

##//Owncast config//##
       ProxyRequests Off
       ProxyPreserveHost On
       AllowEncodedSlashes NoDecode

       <Proxy *>
       Order deny,allow
       Allow from all
       </Proxy>

       ProxyPass / http://localhost:8080/
       ProxyPassReverse / http://localhost:8080/

       RequestHeader set X-Forwarded-Proto "https"
       RequestHeader set X-Forwarded-Port "443"

       # setup the proxy to forward websocket requests properly
       # (note: this proxy automatically converts the secure websocket (wss)
       # to a normal websocket and vice versa.

       RewriteEngine On
       RewriteCond %{HTTP:UPGRADE} ^WebSocket$ [NC,OR]
       RewriteCond %{HTTP:CONNECTION} ^Upgrade$ [NC]
       RewriteRule .* ws://127.0.0.1:8080%{REQUEST_URI} [P,QSA,L]
##//Owncast config//##

SSLCertificateFile /etc/letsencrypt/live/live.pastlife.works/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/live.pastlife.works/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
</VirtualHost>
</IfModule>

```

If I omit everything inside what I marked ##//Owncast config//## I can visit the subdomain, if I include it, it breaks apache completely and I cant visit any domain on the server.

Probably because I didnt understand the lines that Owncast wrote

### I dont get what this is asking me to do:

> setup the proxy to forward websocket requests properly  
> (note: this proxy automatically converts the secure websocket (wss)  
> to a normal websocket and vice versa.

Thank you so much for your help

---

_[View the full topic](https://community.letsencrypt.org/t/help-with-apache-reverse-proxy-to-get-ssl-for-my-owncast-stream-server/175942)._
