<VirtualHost *:441>
	ServerName ava.try.coach
	ServerAlias ava au.ava.try.coach us.ava.try.coach
	DocumentRoot "/www/ava"
	ServerAdmin sam@try.coach
	ErrorLog logs/ava-error_log
	CustomLog logs/ava-access_log combined
	ScriptAlias /x/ /www/ava/x/
	ScriptAlias /a/ /www/ava/a/
	AddHandler cgi-script .cgi
	<Directory "/www/ava">
		Options +Indexes
		Options +FollowSymLinks -SymLinksIfOwnerMatch
		Require all granted
		AllowOverride All
	</Directory>
	<Directory "/www/ava/x">
		AllowOverride None
		Options +ExecCGI -MultiViews
		Options +FollowSymLinks -SymLinksIfOwnerMatch
		Require all granted
	</Directory>
	<Directory "/www/ava/a">
		AllowOverride None
		Options +ExecCGI -MultiViews
		Options +FollowSymLinks -SymLinksIfOwnerMatch
		AuthName "Admin Only"
		AuthType Basic
		AuthUserFile /www/ava/.htpasswd
		Require valid-user
	</Directory>
	<Directory "/www/ava/logout">
		AllowOverride None
		authname "Admin Only"
		authtype basic
		authuserfile /www/ava/logout/.htpasswd
		require valid-user
	</Directory>
	<Directory "/www/ava/log">
		Options +FollowSymLinks -SymLinksIfOwnerMatch
		AllowOverride None
		AuthName "Admin Only"
		AuthType Basic
		AuthUserFile /www/ava/.htpasswd
		Require valid-user
	</Directory>
	AddDefaultCharset utf-8
	RewriteEngine on
#	RewriteRule ^/example$ https://example.com/ [L]
	SSLCertificateFile /etc/letsencrypt/live/try.coach/fullchain.pem
	SSLCertificateKeyFile /etc/letsencrypt/live/try.coach/privkey.pem
	Include /etc/letsencrypt/options-ssl-apache.conf
</VirtualHost>
<VirtualHost *:81>
	ServerName ava.try.coach
	ServerAlias ava au.ava.try.coach us.ava.try.coach
	DocumentRoot "/www/ava"
	ServerAdmin sam@try.coach
	ErrorLog logs/ava-error_log
	CustomLog logs/ava-access_log combined
	RewriteEngine on
	RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L]
</VirtualHost>
