Thanks for replying @JuergenAuer.
I understand what you are saying but the weird thing is I had renewed the certificate twice before without making any changes. And but something happened this time.
This is the nginx config.
upstream jenkins {
server 127.0.0.1:8080 fail_timeout=0;
}
server {
if ($host = devjenkins.goeasyuat.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80;
server_name devjenkins.goeasyuat.com;
error_page 403 /jenkins-on-azure;
location / {
return 301 https://$host$request_uri;
}
location '/.well-known/acme-challenge' {
default_type "text/plain";
root /var/www/letsencrypt;
allow all;
try_files $uri =404;
break;
}
listen 443 ssl;
server_name devjenkins.goeasyuat.com;
ssl_certificate /etc/letsencrypt/live/devjenkins.goeasyuat.com/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/devjenkins.goeasyuat.com/privkey.pem; # managed by Certbot
ssl_protocols TLSv1.2;
ssl_prefer_server_ciphers on;
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
ssl_ciphers ‘ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA2
56:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SH
A384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-S
HA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SH
A:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA’;
ssl_session_timeout 1d;
ssl_session_cache shared:SSL:50m;
ssl_stapling on;
ssl_stapling_verify on;
add_header Strict-Transport-Security max-age=15768000;
location / {
proxy_set_header Host $host:$server_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_redirect http:// https://;
proxy_buffering off;
proxy_pass http://localhost:8080;
}
Where should I remove the redirect from?