The webroot option was deprecated and users should use the /var/run/acme/challenge by default.
The folder itself should be exposed to web.
The simplest way to do this is to create a symlink from /www.
This is a default web location for most routers and should cover most cases.
Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
include $(TOPDIR)/rules.mk
PKG_NAME:=acme-common
-PKG_VERSION:=1.2.0
+PKG_VERSION:=1.3.0
PKG_MAINTAINER:=Toke Høiland-Jørgensen <toke@toke.dk>
PKG_LICENSE:=GPL-3.0-only
#!/bin/sh
+# Create a symlink to webroot
+if [ -d /www/ ] && [ ! -L /www/.well-known/acme-challenge ] && [ ! -d /www/.well-known/acme-challenge/ ]; then
+ mkdir -p /www/.well-known/
+ ln -s /var/run/acme/challenge/ /www/.well-known/acme-challenge
+fi
grep -q '/etc/init.d/acme' /etc/crontabs/root 2>/dev/null && exit 0
echo "0 0 * * * /etc/init.d/acme start" >>/etc/crontabs/root