Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save cameronelliott/8b2c31b22bfe24381cde3049d131471d to your computer and use it in GitHub Desktop.
Save cameronelliott/8b2c31b22bfe24381cde3049d131471d to your computer and use it in GitHub Desktop.
janus gateway sfu with https on digital ocean using caddy.txt
# http://duckdns.org
# https://github.com/RSATom/janus-gateway-snap
snap install janus-gateway
systemctl status snap.janus-gateway.janus-gateway.service
sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list
sudo apt update
sudo apt install caddy
systemctl stop caddy.service
cat <<EOF >/etc/caddy/Caddyfile
xfoo1.duckdns.org:8089 xfoo1.duckdns.org
@foo {
path /janus*
not path /janus.js
}
reverse_proxy @foo localhost:8088
root * /snap/janus-gateway/current/opt/janus/share/janus/demos
file_server
EOF
caddy run -config /etc/caddy/Caddyfile
curl -s -o /dev/null -I -w "%{http_code}" https://xfoo1.duckdns.org:8089
curl -s -o /dev/null -I -w "%{http_code}" https://xfoo1.duckdns.org
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment