Question - Reverse Proxy Settings

Hello,
I tried to configure my eramba with a reverse proxy (using apache2).
After login i get this error after trying to change the default admin email and validate my own

Error occurred

There was a following problem with your request: Unknown error occurred. Invalid repsonse (Code #2)

Here is my .env file :

DB_HOST=mysql
DB_DATABASE=erambadb
DB_USERNAME=eramba
DB_PASSWORD=<my_password>
CACHE_URL=Redis://?server=redis&port=6379&password=&timeout=3
MYSQL_ROOT_PASSWORD=<my_root_password>
USE_PROXY=1
PROXY_HOST=<my_host_private_ip_adress> # i want eramba accessible only on private address
PROXY_PORT=443
USE_PROXY_AUTH=0
PROXY_AUTH_USER=
PROXY_AUTH_PASS=
PUBLIC_ADDRESS=https :// eramba . mydomain . com
DOCKER_DEPLOYMENT=1
LDAPTLS_REQCERT=never

my /etc/apache2/sites-enabled/eramba-ssl.conf File :

<VirtualHost *:443>
ServerName eramba . mydomain . com
SSLEngine on
SSLCertificateKeyFile /etc/ssl/private/mykey.key
SSLCertificateFile /etc/ssl/certs/mycert.crt
SSLCertificateChainFile /etc/ssl/certs/mycert_inter.crt
CustomLog /var/log/apache2/access-eramba.log combined
ErrorLog /var/log/apache2/error-eramba.log
#Security settings
Header always set Strict-Transport-Security “max-age=31536000”
SSLProtocol -all +TLSv1.2 +TLSv1.3
SSLCiphersuite ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-AES256-SHA:AES256-GCM-SHA384:AES256-SHA256:AES256-SHA
SSLHonorCipherOrder On
ProxyPreserveHost On
AllowEncodedSlashes NoDecode
ProxyPass / http://127.0.0.1:8443/ nocanon
ProxyPassReverse / http://127.0.0.1:8443/
ProxyRequests Off
RequestHeader set X-Forwarded-Proto “https”
#Only from authorized networks

Require ip 127.0.0.1 # and my Private IPs go here

Thank you for your help

Hello,

Can you check logs in eramba container, folder /var/www/eramba/app/upgrade/logs.
The best would be if you send us these logs to our support email (support@eramba.org).

Hello @sam thank you for your reply,
I launched eramba without using a reverse proxy for now, and it works as expected.
I’ll let you know when i change the configuration to be using the reverse proxy in the future.

Thanks again.

1 Like