diff options
Diffstat (limited to '')
-rw-r--r-- | debian/open-infrastructure-dehydrated-tools.config | 9 | ||||
-rwxr-xr-x | debian/open-infrastructure-dehydrated-tools.postinst | 13 |
2 files changed, 14 insertions, 8 deletions
diff --git a/debian/open-infrastructure-dehydrated-tools.config b/debian/open-infrastructure-dehydrated-tools.config index dfccb77..e795e68 100644 --- a/debian/open-infrastructure-dehydrated-tools.config +++ b/debian/open-infrastructure-dehydrated-tools.config @@ -53,8 +53,11 @@ db_settitle open-infrastructure-dehydrated-tools/title db_input low open-infrastructure-dehydrated-tools/basedir || true db_go -db_settitle open-infrastructure-dehydrated-tools/title -db_input low open-infrastructure-dehydrated-tools/register || true -db_go +if ! ls /var/lib/dehydrated/accounts/*/account_key.pem > /dev/null 2>&1 +then + db_settitle open-infrastructure-dehydrated-tools/title + db_input low open-infrastructure-dehydrated-tools/register || true + db_go +fi db_stop diff --git a/debian/open-infrastructure-dehydrated-tools.postinst b/debian/open-infrastructure-dehydrated-tools.postinst index fdf39dc..16f1e4d 100755 --- a/debian/open-infrastructure-dehydrated-tools.postinst +++ b/debian/open-infrastructure-dehydrated-tools.postinst @@ -143,11 +143,14 @@ case "${1}" in Install "${BASEDIR}" "${NEW_BASEDIR}" fi - case "${REGISTER}" in - true) - dehydrated --register --accept-terms - ;; - esac + if ! ls /var/lib/dehydrated/accounts/*/account_key.pem > /dev/null 2>&1 + then + case "${REGISTER}" in + true) + dehydrated --register --accept-terms + ;; + esac + fi ;; abort-upgrade|abort-remove|abort-deconfigure) |