From: Toke Høiland-Jørgensen Date: Wed, 22 Aug 2018 14:03:15 +0000 (+0200) Subject: acme: Fix bugs from upstream's change to socat X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=56b6d49ce41a3af2397f9dee840dd62e55273170;p=openwrt-packages.git acme: Fix bugs from upstream's change to socat The upstream acme.sh package changed to using socat instead of netcat; update the dependencies to reflect this, and pass --listen-v6 when running in standalone mode (since socat only listens on IPv4 by default). Also add a missing cleanup call when certificate issuance fails. Signed-off-by: Toke Høiland-Jørgensen --- diff --git a/net/acme/Makefile b/net/acme/Makefile index 09b248e3f..f787f54eb 100644 --- a/net/acme/Makefile +++ b/net/acme/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=acme PKG_VERSION:=2.7.9 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_LICENSE:=GPLv3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz @@ -25,7 +25,7 @@ include $(INCLUDE_DIR)/package.mk define Package/acme SECTION:=net CATEGORY:=Network - DEPENDS:=+curl +ca-bundle +openssl-util +netcat + DEPENDS:=+curl +ca-bundle +openssl-util +socat TITLE:=ACME (Letsencrypt) client endef diff --git a/net/acme/files/run.sh b/net/acme/files/run.sh index 368de26d3..25c36028a 100644 --- a/net/acme/files/run.sh +++ b/net/acme/files/run.sh @@ -187,7 +187,7 @@ issue_cert() acme_args="$acme_args --dns $dns" elif [ -z "$webroot" ]; then log "Using standalone mode" - acme_args="$acme_args --standalone" + acme_args="$acme_args --standalone --listen-v6" else if [ ! -d "$webroot" ]; then err "$main_domain: Webroot dir '$webroot' does not exist!" @@ -211,6 +211,7 @@ issue_cert() err "Restoring staging certificate" mv "$STATE_DIR/${main_domain}.staging" "$STATE_DIR/${main_domain}" fi + post_checks return 1 fi