Make DNS plugin snaps use core20 (#8106)

Fixes #8103.

* Update the DNS plugin generator script to core20 syntax

* Generate new snapcraft.yamls for the DNS plugins

* Update certbot.wrapper to search for python3.8 paths
This commit is contained in:
ohemorange
2020-06-23 09:31:08 -07:00
committed by GitHub
parent 25d1977d4f
commit bce14ae65f
16 changed files with 31 additions and 46 deletions
+2 -3
View File
@@ -3,7 +3,7 @@ summary: Cloudflare DNS Authenticator plugin for Certbot
description: Cloudflare DNS Authenticator plugin for Certbot description: Cloudflare DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-cloudflare adopt-info: certbot-dns-cloudflare
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: CloudXNS DNS Authenticator plugin for Certbot
description: CloudXNS DNS Authenticator plugin for Certbot description: CloudXNS DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-cloudxns adopt-info: certbot-dns-cloudxns
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: DigitalOcean DNS Authenticator plugin for Certbot
description: DigitalOcean DNS Authenticator plugin for Certbot description: DigitalOcean DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-digitalocean adopt-info: certbot-dns-digitalocean
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: DNSimple DNS Authenticator plugin for Certbot
description: DNSimple DNS Authenticator plugin for Certbot description: DNSimple DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-dnsimple adopt-info: certbot-dns-dnsimple
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: DNS Made Easy DNS Authenticator plugin for Certbot
description: DNS Made Easy DNS Authenticator plugin for Certbot description: DNS Made Easy DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-dnsmadeeasy adopt-info: certbot-dns-dnsmadeeasy
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: Gehirn Infrastructure Service DNS Authenticator plugin for Certbot
description: Gehirn Infrastructure Service DNS Authenticator plugin for Certbot description: Gehirn Infrastructure Service DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-gehirn adopt-info: certbot-dns-gehirn
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: Google Cloud DNS Authenticator plugin for Certbot
description: Google Cloud DNS Authenticator plugin for Certbot description: Google Cloud DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-google adopt-info: certbot-dns-google
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: Linode DNS Authenticator plugin for Certbot
description: Linode DNS Authenticator plugin for Certbot description: Linode DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-linode adopt-info: certbot-dns-linode
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: LuaDNS Authenticator plugin for Certbot
description: LuaDNS Authenticator plugin for Certbot description: LuaDNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-luadns adopt-info: certbot-dns-luadns
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: NS1 DNS Authenticator plugin for Certbot
description: NS1 DNS Authenticator plugin for Certbot description: NS1 DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-nsone adopt-info: certbot-dns-nsone
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: OVH DNS Authenticator plugin for Certbot
description: OVH DNS Authenticator plugin for Certbot description: OVH DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-ovh adopt-info: certbot-dns-ovh
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: RFC 2136 DNS Authenticator plugin for Certbot
description: RFC 2136 DNS Authenticator plugin for Certbot description: RFC 2136 DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-rfc2136 adopt-info: certbot-dns-rfc2136
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: Route53 DNS Authenticator plugin for Certbot
description: Route53 DNS Authenticator plugin for Certbot description: Route53 DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-route53 adopt-info: certbot-dns-route53
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+2 -3
View File
@@ -3,7 +3,7 @@ summary: Sakura Cloud DNS Authenticator plugin for Certbot
description: Sakura Cloud DNS Authenticator plugin for Certbot description: Sakura Cloud DNS Authenticator plugin for Certbot
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: certbot-dns-sakuracloud adopt-info: certbot-dns-sakuracloud
parts: parts:
@@ -11,7 +11,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"` snapcraftctl set-version `grep ^version $SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"`
@@ -23,4 +22,4 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- $SNAP/lib/python3.6/site-packages - $SNAP/lib/python3.8/site-packages
+1 -1
View File
@@ -11,7 +11,7 @@ join() {
fi fi
} }
paths=$(for plugin_snap in $(snap connections certbot|sed -n '2,$p'|awk '$1=="content[certbot-1]"{print $3}'|cut -d: -f1); do echo /snap/$plugin_snap/current/lib/python3.6/site-packages; done) paths=$(for plugin_snap in $(snap connections certbot|sed -n '2,$p'|awk '$1=="content[certbot-1]"{print $3}'|cut -d: -f1); do echo /snap/$plugin_snap/current/lib/python3.8/site-packages; done)
export PYTHONPATH=$(join : $PYTHONPATH $paths) export PYTHONPATH=$(join : $PYTHONPATH $paths)
if [ -z "$PYTHONPATH" ]; then if [ -z "$PYTHONPATH" ]; then
unset PYTHONPATH unset PYTHONPATH
+2 -3
View File
@@ -15,7 +15,7 @@ summary: ${DESCRIPTION}
description: ${DESCRIPTION} description: ${DESCRIPTION}
confinement: strict confinement: strict
grade: devel grade: devel
base: core18 base: core20
adopt-info: ${PLUGIN} adopt-info: ${PLUGIN}
parts: parts:
@@ -23,7 +23,6 @@ parts:
plugin: python plugin: python
source: . source: .
constraints: [\$SNAPCRAFT_PART_SRC/snap-constraints.txt] constraints: [\$SNAPCRAFT_PART_SRC/snap-constraints.txt]
python-version: python3
override-pull: | override-pull: |
snapcraftctl pull snapcraftctl pull
snapcraftctl set-version \`grep ^version \$SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"\` snapcraftctl set-version \`grep ^version \$SNAPCRAFT_PART_SRC/setup.py | cut -f2 -d= | tr -d "'[:space:]"\`
@@ -35,6 +34,6 @@ slots:
interface: content interface: content
content: certbot-1 content: certbot-1
read: read:
- \$SNAP/lib/python3.6/site-packages - \$SNAP/lib/python3.8/site-packages
EOF EOF
done done