From 429bf847463ee2caa4b679e63b122d0d6049a1fe Mon Sep 17 00:00:00 2001 From: Erica Portnoy Date: Mon, 13 Jul 2020 18:37:52 -0700 Subject: [PATCH] perhaps only directories can be shared via the contente interface --- certbot-dns-dnsimple/run-bash | 0 certbot-dns-dnsimple/snap/hooks/pre-refresh | 6 +++--- certbot-dns-dnsimple/snap/snapcraft.yaml | 2 +- snap/snapcraft.yaml | 9 +++++++-- 4 files changed, 11 insertions(+), 6 deletions(-) mode change 100644 => 100755 certbot-dns-dnsimple/run-bash diff --git a/certbot-dns-dnsimple/run-bash b/certbot-dns-dnsimple/run-bash old mode 100644 new mode 100755 diff --git a/certbot-dns-dnsimple/snap/hooks/pre-refresh b/certbot-dns-dnsimple/snap/hooks/pre-refresh index 099d9583a..85ad48922 100644 --- a/certbot-dns-dnsimple/snap/hooks/pre-refresh +++ b/certbot-dns-dnsimple/snap/hooks/pre-refresh @@ -7,8 +7,8 @@ if [ -z "$first_install" ]; then exit 0 fi -echo "ls $SNAP/certbot-exec:" -ls $SNAP/certbot-exec -cb_installed=$(grep -oP "__requires__ = 'certbot==\K.*(?=')" $SNAP/certbot-exec) +echo "ls $SNAP/certbot-shared:" +ls $SNAP/certbot-shared +cb_installed=$(grep -oP "__requires__ = 'certbot==\K.*(?=')" $SNAP/certbot-shared) echo "cb_installed: $cb_installed" snapctl set cb-installed="$cb_installed" diff --git a/certbot-dns-dnsimple/snap/snapcraft.yaml b/certbot-dns-dnsimple/snap/snapcraft.yaml index 51ae53f6a..a614f29fd 100644 --- a/certbot-dns-dnsimple/snap/snapcraft.yaml +++ b/certbot-dns-dnsimple/snap/snapcraft.yaml @@ -47,7 +47,7 @@ plugs: certbot-version: interface: content content: version-1 - target: $SNAP/certbot-exec + target: $SNAP/certbot-shared hooks: post-refresh: diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index e41cc4eea..285c57a57 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -79,11 +79,16 @@ parts: cd $SNAPCRAFT_PART_SRC python3 tools/strip_hashes.py letsencrypt-auto-source/pieces/dependency-requirements.txt | grep -v python-augeas > snap-constraints.txt snapcraftctl set-version `git describe|sed s/^v//` - wrappers: plugin: dump source: . stage: [certbot.wrapper] + shared-version: + plugin: dump + source: . + stage: [certbot-version/__init__.py] + organize: + $SNAPCRAFT_PART_SRC/certbot/certbot/__init__.py: certbot-version/__init__.py plugs: plugin: @@ -95,4 +100,4 @@ slots: certbot-version: interface: content content: version-1 - read: [$SNAP/bin/certbot] + read: [$SNAP/certbot-version]