diff options
Diffstat (limited to 'debian/local')
-rw-r--r-- | debian/local/apache2/ttyd.conf | 25 | ||||
-rw-r--r-- | debian/local/examples/apache2-authbasic-file.conf | 10 | ||||
-rw-r--r-- | debian/local/examples/apache2-authbasic-ip.conf | 8 |
3 files changed, 43 insertions, 0 deletions
diff --git a/debian/local/apache2/ttyd.conf b/debian/local/apache2/ttyd.conf new file mode 100644 index 0000000..66b1850 --- /dev/null +++ b/debian/local/apache2/ttyd.conf @@ -0,0 +1,25 @@ +# /etc/apache2/conf-available/ttyd.conf + +<IfModule rewrite_module> + <IfModule proxy_http_module> + <IfModule proxy_wstunnel_module> + ProxyPreserveHost On + ProxyRequests Off + + ProxyPass /ttyd/token ws://localhost:7681/token + ProxyPassReverse /ttyd/token ws://localhost:7681/token + + ProxyPass /ttyd/ws ws://localhost:7681/ws + ProxyPassReverse /ttyd/ws ws://localhost:7681/ws + + ProxyPass /ttyd http://localhost:7681 + ProxyPassReverse /ttyd http://localhost:7681 + + <IfFile /etc/ttyd/apache2-auth.conf> + <Location /ttyd> + Include /etc/ttyd/apache2-auth.conf + </Location> + </IfFile> + </IfModule> + </IfModule> +</IfModule> diff --git a/debian/local/examples/apache2-authbasic-file.conf b/debian/local/examples/apache2-authbasic-file.conf new file mode 100644 index 0000000..5f28cb9 --- /dev/null +++ b/debian/local/examples/apache2-authbasic-file.conf @@ -0,0 +1,10 @@ +# /etc/ttyd/apache2-auth.conf + +<IfFile /etc/ttyd/htpasswd> + AuthName "ttyd" + AuthBasicProvider file + AuthType basic + + AuthUserFile /etc/ttyd/htpasswd + Require valid-user +</IfFile> diff --git a/debian/local/examples/apache2-authbasic-ip.conf b/debian/local/examples/apache2-authbasic-ip.conf new file mode 100644 index 0000000..8507a20 --- /dev/null +++ b/debian/local/examples/apache2-authbasic-ip.conf @@ -0,0 +1,8 @@ +# /etc/ttyd/apache2-auth.conf + +Order deny,allow +Deny from all + +Allow from 10.0.0.0/8 +Allow from 172.16.0.0/12 +Allow from 192.168.0.0/16 |