-
Notifications
You must be signed in to change notification settings - Fork 2
Description
log如下:
[Sun Dec 1 03:24:33 UTC 2024] 生成默认证书, 配置文件中使用,否则nginx启动会失败
[Sun Dec 1 03:24:33 UTC 2024] create default cert to :/etc/nginx/ssl
....+...+..+.+......+........+.............+........+......+.+........+....+........+...+....+..+.+.........+.........+............+...+.....+....+...+...+......+......+..+++++++++++++
..+..+++++++++++++++++++++++++++++++++++++++++++++.+.....+.........+......+...+......+.+...+.....................+++++++++++++++++++++++++++++++++++++++++++++.....+..............+...............+.+..+.+..............+.+..+.......+...+.....+............+.......+......+.........+...+...........+.+...+......+..+.........+...+.+..+.........+....+......+......+...+......+.........+......+......+...+..+............+...+...+....+..+.+...+..+......................+...........+....+.....+......+......+..........+.........+..+...+++++
[Sun Dec 1 03:24:33 UTC 2024] Start nginx
[Sun Dec 1 03:24:33 UTC 2024] sleep 2 second to start Acme.sh...
[Sun Dec 1 03:24:35 UTC 2024] Start Acme.sh...
[Sun Dec 1 03:24:35 UTC 2024] SSL_DIR :/etc/nginx/ssl
[Sun Dec 1 03:24:35 UTC 2024] mail :17****@qq.com
[Sun Dec 1 03:24:35 UTC 2024] RELOAD_CMD :nginx -s reload
[Sun Dec 1 03:24:35 UTC 2024] Use dns plugin: dns_ali
[Sun Dec 1 03:24:35 UTC 2024] Issue the cert: xx.xxx.com with options: --dns dns_ali-d xx.xxx.com
[Sun Dec 1 03:24:36 UTC 2024] Changed default CA to: https://acme-v02.api.letsencrypt.org/directory
[Sun Dec 1 03:24:36 UTC 2024] 1、acme.sh register ..
[Sun Dec 1 03:24:37 UTC 2024] Account key creation OK.
[Sun Dec 1 03:24:37 UTC 2024] Registering account: https://acme-v02.api.letsencrypt.org/directory
[Sun Dec 1 03:24:41 UTC 2024] Registered
[Sun Dec 1 03:24:41 UTC 2024] ACCOUNT_THUMBPRINT='U1xri9gEd**********************'
[Sun Dec 1 03:24:41 UTC 2024] 2、acme.sh issue ..
[Sun Dec 1 03:24:41 UTC 2024] Unknown parameter: xx.xxx.com
[Sun Dec 1 03:24:41 UTC 2024] 3、acme.sh install-cert ..
[Sun Dec 1 03:24:41 UTC 2024] Unknown parameter: xx.xxx.com
[Sun Dec 1 03:24:41 UTC 2024] Start acme.sh crond
配置如下:
docker run -d -p 188:80 -p 4333:443 -v "/opt/docker/data/web":/data/web
-v "/opt/docker/data/mynginx/nginx/ssl":/etc/nginx/ssl
-v "/opt/docker/data/mynginx/nginx/conf.d":/etc/nginx/conf.d
-v "/opt/docker/data/mynginx/acme_cert":/acme_cert
-e SslDomains="xx.xxx.com"
-e SslServer="letsencrypt"
-e mail="17************@qq.com"
-e dns="dns_ali" -e Ali_Key="xxxxxxxxx"
-e Ali_Secret="xxxxxxxxxxxxxxx"
--name nginx xiaojun207/nginx:latest