Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. crt.sh | example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.
My domain is: www.jionlp.com
I ran this command: certbot --nginx -d www.jionlp.com -v
It produced this output:
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Python 3.8 support will be dropped in the next planned release of Certbot - please upgrade your Python version.
Plugins selected: Authenticator nginx, Installer nginx
Requesting a certificate for www.jionlp.com
Performing the following challenges:
http-01 challenge for www.jionlp.com
Waiting for verification...
Challenge failed for domain www.jionlp.com
http-01 challenge for www.jionlp.com
Certbot failed to authenticate some domains (authenticator: nginx). The Certificate Authority reported these problems:
Domain: www.jionlp.com
Type: unauthorized
Detail: 182.92.160.94: Invalid response from http://www.jionlp.com/.well-known/acme-challenge/hhORNhTzBV0xE49MADGou9aylCT3eMNP4YIahX-SfcA: "<!doctype html><html lang=\"\"><head><meta charset=\"utf-8\"><meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\"><meta name=\"viewpo"
Hint: The Certificate Authority failed to verify the temporary nginx configuration changes made by Certbot. Ensure the listed domains point to this nginx server and that it is accessible from the internet.
Cleaning up challenges
Some challenges have failed.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.
My web server is (include version): nginx version: nginx/1.18.0 (Ubuntu)
The operating system my web server runs on is (include version): Ubuntu 20.04.3 LTS \n \l
My hosting provider, if applicable, is: aliyun
I can login to a root shell on my machine (yes or no, or I don't know): yes
I'm using a control panel to manage my site (no, or provide the name and version of the control panel): no
The version of my client is (e.g. output of certbot --version
or certbot-auto --version
if you're using Certbot): certbot 3.0.1
Appendix:
Im hosting my website on aliyun(cloud server provided by alibaba), the public IP is 182.92.160.94. I wrapped my nginx server in a docker container, which is started like this:
b5f3aacf1839 jionlp_online:v1.0 "/bin/bash" 2 years ago Up 6 weeks 16666/tcp, 17777/tcp, 18888/tcp, 0.0.0.0:80->80/tcp, :::80->80/tcp, 19999/tcp frontend_server
And my nginx configure file is like this :
worker_processes 1;
error_log /root/jionlp_online/JioNLP_frontend/nginx/nginx_error.log warn;
# Change pid to allow no super user to run
# pid /tmp/nginx.pid;
user root;
worker_rlimit_nofile 65535;
events {
worker_connections 1024;
}
http {
proxy_temp_path /tmp/proxy_temp;
client_body_temp_path /tmp/client_temp;
fastcgi_temp_path /tmp/fastcgi_temp;
uwsgi_temp_path /tmp/uwsgi_temp;
scgi_temp_path /tmp/scgi_temp;
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /root/jionlp_online/JioNLP_frontend/nginx/access.log main;
sendfile on;
keepalive_timeout 60;
server {
listen 80; #监听端口
server_name 0.0.0.0; #域名
root /root/jionlp_online/JioNLP_frontend/dist; #站点目录
gzip on;
gzip_min_length 1k;
gzip_buffers 4 16k;
gzip_http_version 1.0;
gzip_comp_level 9;
gzip_types text/plain application/javascript application/x-javascript text/css text/javascript application/xml image/jpeg image/gif image/png;
gzip_vary on;
index index.html;
location / {
root /root/jionlp_online/JioNLP_frontend/dist;
index index.html;
try_files $uri $uri/ /index.html;
}
location ~ .*\.(txt)$ {
add_header Access-Control-Allow-Origin *;
add_header Access-Control-Allow-Methods 'GET, POST, OPTIONS';
add_header Access-Control-Allow-Headers 'DNT,X-Mx-ReqToken,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Authorization';
if ($request_method = 'OPTIONS') {
return 204;
}
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf|ico)$
{
expires 30d;
# access_log off;
}
location ~ .*\.(js|css)?$
{
expires 15d;
# access_log off;
}
access_log on;
}
# include /etc/nginx/conf.d/*.conf;
}
I am curious about the possibility of changing the open port 443 to this server, maybe??
and the nginx -T
shows the below:
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
# configuration file /etc/nginx/nginx.conf:
worker_processes 1;
error_log /root/jionlp_online/JioNLP_frontend/nginx/nginx_error.log warn;
# Change pid to allow no super user to run
# pid /tmp/nginx.pid;
user root;
worker_rlimit_nofile 65535;
events {
worker_connections 1024;
}
http {
proxy_temp_path /tmp/proxy_temp;
client_body_temp_path /tmp/client_temp;
fastcgi_temp_path /tmp/fastcgi_temp;
uwsgi_temp_path /tmp/uwsgi_temp;
scgi_temp_path /tmp/scgi_temp;
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /root/jionlp_online/JioNLP_frontend/nginx/access.log main;
sendfile on;
keepalive_timeout 60;
server {
listen 80; #监听端口
server_name 0.0.0.0; #域名
root /root/jionlp_online/JioNLP_frontend/dist; #站点目录
gzip on;
gzip_min_length 1k;
gzip_buffers 4 16k;
gzip_http_version 1.0;
gzip_comp_level 9;
gzip_types text/plain application/javascript application/x-javascript text/css text/javascript application/xml image/jpeg image/gif image/png;
gzip_vary on;
index index.html;
location / {
root /root/jionlp_online/JioNLP_frontend/dist;
index index.html;
try_files $uri $uri/ /index.html;
}
location ~ .*\.(txt)$ {
add_header Access-Control-Allow-Origin *;
application/vnd.google-earth.kml+xml kml;
application/vnd.google-earth.kmz kmz;
application/x-7z-compressed 7z;
application/x-cocoa cco;
application/x-java-archive-diff jardiff;
application/x-java-jnlp-file jnlp;
application/x-makeself run;
application/x-perl pl pm;
application/x-pilot prc pdb;
application/x-rar-compressed rar;
application/x-redhat-package-manager rpm;
application/x-sea sea;
application/x-shockwave-flash swf;
application/x-stuffit sit;
application/x-tcl tcl tk;
application/x-x509-ca-cert der pem crt;
application/x-xpinstall xpi;
application/xhtml+xml xhtml;
application/xspf+xml xspf;
application/zip zip;
application/octet-stream bin exe dll;
application/octet-stream deb;
application/octet-stream dmg;
application/octet-stream iso img;
application/octet-stream msi msp msm;
application/vnd.openxmlformats-officedocument.wordprocessingml.document docx;
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet xlsx;
application/vnd.openxmlformats-officedocument.presentationml.presentation pptx;
audio/midi mid midi kar;
audio/mpeg mp3;
audio/ogg ogg;
audio/x-m4a m4a;
audio/x-realaudio ra;
video/3gpp 3gpp 3gp;
video/mp2t ts;
video/mp4 mp4;
video/mpeg mpeg mpg;
video/quicktime mov;
video/webm webm;
video/x-flv flv;
video/x-m4v m4v;
video/x-mng mng;
video/x-ms-asf asx asf;
video/x-ms-wmv wmv;
video/x-msvideo avi;
}
This really confused me for about 2 days and have no trace of clues.
Really appreciated your help. Thx.