diff --git a/certbot-dns-dnsimple/snap/hooks/post-refresh b/certbot-dns-dnsimple/snap/hooks/post-refresh index 8947c96bb..e15e7b54b 100644 --- a/certbot-dns-dnsimple/snap/hooks/post-refresh +++ b/certbot-dns-dnsimple/snap/hooks/post-refresh @@ -4,6 +4,7 @@ cb_installed="$(snapctl get cb-installed)" if [ -z "$cb_installed" ]; then + echo "cb_installed not set, not doing version comparison check" exit 0 fi @@ -11,6 +12,7 @@ fi cb_required=$(grep -oP "certbot>=\K.*(?=')" $SNAP/setup.py) if [ "$cb_installed" -lt "$cb_required" ]; then - echo "Certbot needs to be updated before this plugin can be updated; will try again on next refresh." + echo "Certbot is version $cb_installed but needs to be at least $cb_required before \ + this plugin can be updated; will try again on next refresh." exit 1 fi diff --git a/certbot-dns-dnsimple/snap/hooks/pre-refresh b/certbot-dns-dnsimple/snap/hooks/pre-refresh index b3a4797d3..099d9583a 100644 --- a/certbot-dns-dnsimple/snap/hooks/pre-refresh +++ b/certbot-dns-dnsimple/snap/hooks/pre-refresh @@ -3,9 +3,12 @@ first_install="$(snapctl get first-install)" if [ -z "$first_install" ]; then snapctl set first-install="false" + echo "first install, not doing any version comparison checks" exit 0 fi +echo "ls $SNAP/certbot-exec:" +ls $SNAP/certbot-exec cb_installed=$(grep -oP "__requires__ = 'certbot==\K.*(?=')" $SNAP/certbot-exec) -echo "cb_installed $cb_installed" +echo "cb_installed: $cb_installed" snapctl set cb-installed="$cb_installed"