destromachines.com, Nginx, debian buster-slim, docker container, certbot 0.31.0
Docker container installs cron, does not install or use systemd. cron is stood up using supervisord.
contents of /etc/cron.d/certbot as found:
0 */12 * * * root test -x /usr/bin/certbot -a ! -d /run/systemd/system && perl -e ‘sleep int(rand(43200))’ && certbot -q renew
From the command line certbot renew --dry-run works just fine and uses webroot.
It does not look like the command in the crontab works: /usr/bin/certbot -a ! -d /run/systemd/system && perl -e ‘sleep int(rand(43200))’ && certbot -q renew
fails with: “The requested ! plugin does not appear to be installed”
/var/log/letsencrypt/letsencrypt.log:
2019-09-21 17:25:06,256:DEBUG:certbot.main:certbot version: 0.31.0
2019-09-21 17:25:06,257:DEBUG:certbot.main:Arguments: [’-a’, ‘!’, ‘-d’, ‘/run/systemd/system’]
2019-09-21 17:25:06,257:DEBUG:certbot.main:Discovered plugins: PluginsRegistry(PluginEntryPoint#manual,PluginEntryPoint#nginx,PluginEntryPoint#null,PluginEntryPoint#standalone,PluginEntryPoint#webroot)
2019-09-21 17:25:06,267:DEBUG:certbot.log:Root logging level set at 20
2019-09-21 17:25:06,267:INFO:certbot.log:Saving debug log to /var/log/letsencrypt/letsencrypt.log
2019-09-21 17:25:06,269:DEBUG:certbot.plugins.selection:Requested authenticator ! and installer None
2019-09-21 17:25:06,435:DEBUG:certbot.plugins.selection:Single candidate plugin: * nginx
Description: Nginx Web Server plugin
Interfaces: IAuthenticator, IInstaller, IPlugin
Entry point: nginx = certbot_nginx.configurator:NginxConfigurator
Initialized: <certbot_nginx.configurator.NginxConfigurator object at 0x7f5db80ea978>
Prep: True
2019-09-21 17:25:06,436:DEBUG:certbot.plugins.selection:No candidate plugin
2019-09-21 17:25:06,436:DEBUG:certbot.plugins.selection:Selected authenticator None and installer <certbot_nginx.configurator.NginxConfigurator object at 0x7f5db80ea978>
It looks like it’s trying to use the nginx plugin but its not installed because the site is configured to use webroot.
How do I fix it?
Tony