<VirtualHost *:80>
  ServerAdmin me@mydomain.com

  ErrorLog ${APACHE_LOG_DIR}/error.log
  CustomLog ${APACHE_LOG_DIR}/access.log combined

  RequestHeader set X-Forwarded-Proto "https"

  <Proxy *>
     Authtype Basic
     Authname "Restricted Access"
     AuthUserFile /var/www/access/.htpasswd
     Require valid-user
     Order deny,allow
     Allow from all
  </Proxy>


  ProxyPass / http://127.0.0.1:3333/ retry=1 acquire=3000 timeout=600 Keepalive=On
  ProxyPreserveHost On
  ProxyRequests Off
  ProxyVia Off

  ErrorLog ${APACHE_LOG_DIR}/error.log
  CustomLog ${APACHE_LOG_DIR}/access.log combined

</VirtualHost>
