mirror of
https://github.com/plantroon/acme.sh.git
synced 2024-11-09 16:01:46 +00:00
commit
12615c46f8
14
.github/workflows/DNS.yml
vendored
14
.github/workflows/DNS.yml
vendored
@ -61,22 +61,22 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
cd ../acmetest
|
cd ../acmetest
|
||||||
if [ "${{ secrets.TokenName1}}" ] ; then
|
if [ "${{ secrets.TokenName1}}" ] ; then
|
||||||
echo "${{ secrets.TokenName1}}=${{ secrets.TokenValue1}}" >> env.list
|
echo "${{ secrets.TokenName1}}=${{ secrets.TokenValue1}}" >> docker.env
|
||||||
fi
|
fi
|
||||||
if [ "${{ secrets.TokenName2}}" ] ; then
|
if [ "${{ secrets.TokenName2}}" ] ; then
|
||||||
echo "${{ secrets.TokenName2}}=${{ secrets.TokenValue2}}" >> env.list
|
echo "${{ secrets.TokenName2}}=${{ secrets.TokenValue2}}" >> docker.env
|
||||||
fi
|
fi
|
||||||
if [ "${{ secrets.TokenName3}}" ] ; then
|
if [ "${{ secrets.TokenName3}}" ] ; then
|
||||||
echo "${{ secrets.TokenName3}}=${{ secrets.TokenValue3}}" >> env.list
|
echo "${{ secrets.TokenName3}}=${{ secrets.TokenValue3}}" >> docker.env
|
||||||
fi
|
fi
|
||||||
if [ "${{ secrets.TokenName4}}" ] ; then
|
if [ "${{ secrets.TokenName4}}" ] ; then
|
||||||
echo "${{ secrets.TokenName4}}=${{ secrets.TokenValue4}}" >> env.list
|
echo "${{ secrets.TokenName4}}=${{ secrets.TokenValue4}}" >> docker.env
|
||||||
fi
|
fi
|
||||||
if [ "${{ secrets.TokenName5}}" ] ; then
|
if [ "${{ secrets.TokenName5}}" ] ; then
|
||||||
echo "${{ secrets.TokenName5}}=${{ secrets.TokenValue5}}" >> env.list
|
echo "${{ secrets.TokenName5}}=${{ secrets.TokenValue5}}" >> docker.env
|
||||||
fi
|
fi
|
||||||
echo "TEST_DNS_NO_WILDCARD" >> env.list
|
echo "TEST_DNS_NO_WILDCARD" >> docker.env
|
||||||
echo "TEST_DNS_SLEEP" >> env.list
|
echo "TEST_DNS_SLEEP" >> docker.env
|
||||||
- name: Run acmetest
|
- name: Run acmetest
|
||||||
run: cd ../acmetest && ./rundocker.sh testall
|
run: cd ../acmetest && ./rundocker.sh testall
|
||||||
|
|
||||||
|
2
.github/workflows/Linux.yml
vendored
2
.github/workflows/Linux.yml
vendored
@ -20,7 +20,7 @@ jobs:
|
|||||||
Linux:
|
Linux:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: ["ubuntu:latest", "debian:latest", "almalinux:latest", "fedora:latest", "centos:latest", "opensuse/leap:latest", "alpine:latest", "oraclelinux:8", "kalilinux/kali", "archlinux:latest", "mageia", "gentoo/stage3-amd64", "clearlinux:latest"]
|
os: ["ubuntu:latest", "debian:latest", "almalinux:latest", "fedora:latest", "centos:latest", "opensuse/leap:latest", "alpine:latest", "oraclelinux:8", "kalilinux/kali", "archlinux:latest", "mageia", "gentoo/stage3-amd64"]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
TEST_LOCAL: 1
|
TEST_LOCAL: 1
|
||||||
|
12
acme.sh
12
acme.sh
@ -20,6 +20,8 @@ _SUB_FOLDER_DEPLOY="deploy"
|
|||||||
|
|
||||||
_SUB_FOLDERS="$_SUB_FOLDER_DNSAPI $_SUB_FOLDER_DEPLOY $_SUB_FOLDER_NOTIFY"
|
_SUB_FOLDERS="$_SUB_FOLDER_DNSAPI $_SUB_FOLDER_DEPLOY $_SUB_FOLDER_NOTIFY"
|
||||||
|
|
||||||
|
CA_LETSENCRYPT_V1="https://acme-v01.api.letsencrypt.org/directory"
|
||||||
|
|
||||||
CA_LETSENCRYPT_V2="https://acme-v02.api.letsencrypt.org/directory"
|
CA_LETSENCRYPT_V2="https://acme-v02.api.letsencrypt.org/directory"
|
||||||
CA_LETSENCRYPT_V2_TEST="https://acme-staging-v02.api.letsencrypt.org/directory"
|
CA_LETSENCRYPT_V2_TEST="https://acme-staging-v02.api.letsencrypt.org/directory"
|
||||||
|
|
||||||
@ -3161,9 +3163,9 @@ _checkConf() {
|
|||||||
FOUND_REAL_NGINX_CONF="$2"
|
FOUND_REAL_NGINX_CONF="$2"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
if cat "$2" | tr "\t" " " | grep "^ *include +.*;" >/dev/null; then
|
if cat "$2" | tr "\t" " " | grep "^ *include *.*;" >/dev/null; then
|
||||||
_debug "Try include files"
|
_debug "Try include files"
|
||||||
for included in $(cat "$2" | tr "\t" " " | grep "^ *include +.*;" | sed "s/include //" | tr -d " ;"); do
|
for included in $(cat "$2" | tr "\t" " " | grep "^ *include *.*;" | sed "s/include //" | tr -d " ;"); do
|
||||||
_debug "check included $included"
|
_debug "check included $included"
|
||||||
if ! _startswith "$included" "/" && _exists dirname; then
|
if ! _startswith "$included" "/" && _exists dirname; then
|
||||||
_relpath="$(dirname "$_c_file")"
|
_relpath="$(dirname "$_c_file")"
|
||||||
@ -3380,6 +3382,8 @@ _on_before_issue() {
|
|||||||
if [ "$_chk_pre_hook" ]; then
|
if [ "$_chk_pre_hook" ]; then
|
||||||
_info "Run pre hook:'$_chk_pre_hook'"
|
_info "Run pre hook:'$_chk_pre_hook'"
|
||||||
if ! (
|
if ! (
|
||||||
|
export Le_Domain="$_chk_main_domain"
|
||||||
|
export Le_Alt="$_chk_alt_domains"
|
||||||
cd "$DOMAIN_PATH" && eval "$_chk_pre_hook"
|
cd "$DOMAIN_PATH" && eval "$_chk_pre_hook"
|
||||||
); then
|
); then
|
||||||
_err "Error when run pre hook."
|
_err "Error when run pre hook."
|
||||||
@ -5108,7 +5112,7 @@ renew() {
|
|||||||
|
|
||||||
. "$DOMAIN_CONF"
|
. "$DOMAIN_CONF"
|
||||||
_debug Le_API "$Le_API"
|
_debug Le_API "$Le_API"
|
||||||
if [ -z "$Le_API" ]; then
|
if [ -z "$Le_API" ] || [ "$CA_LETSENCRYPT_V1" = "$Le_API" ]; then
|
||||||
#if this is from an old version, Le_API is empty,
|
#if this is from an old version, Le_API is empty,
|
||||||
#so, we force to use letsencrypt server
|
#so, we force to use letsencrypt server
|
||||||
Le_API="$CA_LETSENCRYPT_V2"
|
Le_API="$CA_LETSENCRYPT_V2"
|
||||||
@ -5743,7 +5747,7 @@ uninstallcronjob() {
|
|||||||
_info "Removing cron job"
|
_info "Removing cron job"
|
||||||
cr="$($_CRONTAB -l | grep "$PROJECT_ENTRY --cron")"
|
cr="$($_CRONTAB -l | grep "$PROJECT_ENTRY --cron")"
|
||||||
if [ "$cr" ]; then
|
if [ "$cr" ]; then
|
||||||
if _exists uname && uname -a | grep solaris >/dev/null; then
|
if _exists uname && uname -a | grep SunOS >/dev/null; then
|
||||||
$_CRONTAB -l | sed "/$PROJECT_ENTRY --cron/d" | $_CRONTAB --
|
$_CRONTAB -l | sed "/$PROJECT_ENTRY --cron/d" | $_CRONTAB --
|
||||||
else
|
else
|
||||||
$_CRONTAB -l | sed "/$PROJECT_ENTRY --cron/d" | $_CRONTAB -
|
$_CRONTAB -l | sed "/$PROJECT_ENTRY --cron/d" | $_CRONTAB -
|
||||||
|
Loading…
Reference in New Issue
Block a user