When run the phpMyAdmin tool in a Docker container and configured in the NGINX virtualhost with the reverse proxy received the warning appearing at the phpMyAdmin login screen.

There is a mismatch between HTTPS indicated on the server and client. This can lead to a non working phpMyAdmin or a security risk. Please fix your server configuration to indicate HTTPS properly.

We should add the nginx configuration on the location,

proxy_set_header X-Forwarded-Proto https;

So, the overall sample code here,
server {
        listen 80;
        server_name phpmyadmin.thelinuxfaaq.com;
        return 301 https://$server_name$request_uri;
....
....
}
server {
    listen 443 ssl http2;
    server_name phpmyadmin.thelinuxfaaq.com;
    ssl_certificate /etc/nginx/ssl/sslcert.crt;
    ssl_certificate_key /etc/nginx/ssl/sslcert.key;
    ....
    ....
 
    location / {
        proxy_pass http://0.0.0.0:8080;
        proxy_set_header X-Forwarded-Host $host;
        proxy_set_header X-Forwarded-Proto https;
        proxy_set_header X-Forwarded-Server $host;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_redirect off;
    }
}

Once you have modified the NGINX virtual host configuration, should test and restart the NGINX,


$ sudo nginx -t

$ sudo service nginx restart