I have a live app running on port :8080 I managed to secure my site and redirect the app to listen on port 80 (http://142.93.118.89/#/dashboard), however when I tried to setup a ProxyPassReverse it doesn't work. What Am I doing wrong here? Why can't I access https://www.ofornecedor.com.br? Thanks root@ubuntu-suppliers:/etc/apache2/sites-available# cat ofornecedor.com.br-le-ssl.conf <IfModule mod_ssl.c> <VirtualHost *:443> # ServerAdmin webmaster@localhost # ServerName ofornecedor.com.br # ServerAlias www.ofornecedor.com.br # DocumentRoot /var/www/ofornecedor.com.br # ErrorLog ${APACHE_LOG_DIR}/error.log # CustomLog ${APACHE_LOG_DIR}/access.log combined ServerName ofornecedor.com.br ServerAlias www.ofornecedor.com.br ProxyPreserveHost On ProxyRequests Off ProxyPass / http://127.0.0.1:8080/ ProxyPassReverse / http://127.0.0.1:8080/ Include /etc/letsencrypt/options-ssl-apache.conf SSLCertificateFile /etc/letsencrypt/live/ofornecedor.com.br/fullchain.pem SSLCertificateKeyFile /etc/letsencrypt/live/ofornecedor.com.br/privkey.pem </VirtualHost> </IfModule> root@ubuntu-suppliers:/etc/apache2/sites-available# cat ofornecedor.com.br.conf <VirtualHost *:80> ProxyPreserveHost On ProxyPass / http://127.0.0.1:8080/ ProxyPassReverse / http://127.0.0.1:8080/ # ServerAdmin webmaster@localhost ServerName ofornecedor.com.br ServerAlias www.ofornecedor.com.br # DocumentRoot /var/www/ofornecedor.com.br ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined RewriteEngine on RewriteCond %{SERVER_NAME} =ofornecedor.com.br [OR] RewriteCond %{SERVER_NAME} =www.ofornecedor.com.br RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent] </VirtualHost> root@ubuntu-suppliers:/etc/apache2/sites-available# Code (markup): Thanks
Hey Fave. Thanks for your reply. So what Am I doing wrong here? I also defined ProxyPass under port 443. ProxyPreserveHost On ProxyRequests Off ProxyPass / http://127.0.0.1:8080/ ProxyPassReverse / http://127.0.0.1:8080/ Code (markup): Why Am I able to access the site with the IP address but not with DNS name? Thanks!
I'm not a proxy expert unfortunately I am a web host but DNS are listening on port 53 usually. Do you have a firewall blocking ports?
Ensure that all necessary Apache modules are enabled on your server: sudo a2enmod proxy sudo a2enmod proxy_http sudo a2enmod proxy_balancer Code (markup): If you are still getting the error, check the Apache error log for more details.