Use the python script call approach

This commit is contained in:
Adrien Ferrand 2020-09-29 00:04:32 +02:00
parent 19abc12d66
commit 0f61b9cd53
2 changed files with 2 additions and 7 deletions

View file

@ -1,5 +0,0 @@
"""Certbot entrypoint for package execution"""
from certbot.main import main
if __name__ == "__main__":
main()

View file

@ -20,13 +20,13 @@ adopt-info: certbot
apps:
certbot:
command: bin/python3 -m certbot
command: bin/python3 $SNAP/bin/certbot
environment:
PATH: "$SNAP/bin:$SNAP/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"
AUGEAS_LENS_LIB: "$SNAP/usr/share/augeas/lenses/dist"
CERTBOT_SNAPPED: "True"
renew:
command: bin/python3 -m certbot -q renew
command: bin/python3 $SNAP/bin/certbot -q renew
daemon: oneshot
environment:
PATH: "$SNAP/bin:$SNAP/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"