Hi,
I would prefer not to post the domain because I don't want the person I am trying to host site for to worry if they searched for their website, and came across these issues.
I am using acme_sh
. I set up my own crontab to remind me because in the past I was using certbot, and it failed to renew, and the website went down. Now I changed to acme_sh
(because I am using debian, since I wish not to use snap
, which could issue an update at any time and break things. I followed the acme_sh
's installation/cert issue/cert installation procedure and it all went well. Their documentation says it should auto renew after 60 days.
Issue command:
sudo -u username /home/username/.acme.sh/acme.sh --issue --server letsencrypt -d example.com -d www.example.com -w /var/www/example.com/public'
Install command:
sudo -u username /home/username/.acme.sh/acme.sh --install-cert -d example.com --fullchain-file /var/www/example.com/private/cert/fullchain.pem --key-file /var/www/example.com/private/cert/key.pem --cert-file /var/www/example.com/private/cert/cert.pem
64 days later...
When I run my own cron job to check if it has expired (using nmap -p 443 --script ssl-cert example.com
, I get (note it should have renewed 4 days ago):
The certificate is valid from 2022-04-21 to 2022-07-20, 64 days since issue (should renew after 60), 25 days remaining (cert valid for 90 days)
There is no file (from reading other people problems they referred to this log):
/home/username/.acme.sh/acme.sh.log
./acme.sh --renew-all
prints nothing
$ ./acme.sh --renew-all
$
This is whats in the root's hoem dir:
root@demo:~/.acme.sh# ll
total 24
drwxr-xr-x 4 root root 4096 Jun 23 14:29 .
drwx------ 7 root root 4096 Jun 23 14:30 ..
-rw-r--r-- 1 root root 73 Jun 23 14:36 account.conf
drwxr-xr-x 3 root root 4096 Jun 23 14:29 ca
drwxr-xr-x 3 root root 4096 Jun 23 14:29 example.co.za
-rw-r--r-- 1 root root 490 Jun 23 14:36 http.header
And this is what is in the users home dir:
username@demo:~/.acme.sh$ ll
total 240
drwx------ 5 username username 4096 Jun 23 14:29 .
drwxr-xr-x 7 username username 4096 Jun 23 14:30 ..
-rw-r--r-- 1 username username 200 Jun 23 14:29 account.conf
-rwxr-xr-x 1 username username 216188 Jun 23 14:29 acme.sh
-rw-r--r-- 1 username username 96 Jun 23 14:29 acme.sh.env
drwxr-xr-x 2 username username 4096 Jun 23 14:29 deploy
drwxr-xr-x 2 username username 4096 Jun 23 14:29 dnsapi
drwxr-xr-x 2 username username 4096 Jun 23 14:29 notify
These are the daily cronjobs (cert_check
is the cron job I made):
$ sudo -u username run-parts --test /etc/cron.daily
/etc/cron.daily/apt-compat
/etc/cron.daily/cert_check
/etc/cron.daily/dpkg
/etc/cron.daily/logrotate
/etc/cron.daily/man-db
/etc/cron.daily/sysstat
Here are the not updated certs:
/var/www/example.com/private/cert$ ll
total 24
drwxrwx--- 2 username www-data 4096 Apr 21 13:52 .
drwxrwx--- 3 username www-data 4096 Apr 21 13:52 ..
-rw-rw---- 1 username www-data 1891 Apr 21 14:22 cert.pem
-rw-rw---- 1 username www-data 5642 Apr 21 14:22 fullchain.pem
-rw-rw---- 1 username www-data 1675 Apr 21 14:22 key.pem
What else can I try?