start.sh 478 B

1234567891011121314151617181920212223
  1. #!/bin/bash
  2. # fonts color
  3. Green="\033[32m"
  4. Red="\033[31m"
  5. Yellow="\033[33m"
  6. GreenBG="\033[42;37m"
  7. RedBG="\033[41;37m"
  8. Font="\033[0m"
  9. # fonts color
  10. DOMAIN=$(cat /conf/account.conf | awk -F= '{if($1~"DOMAIN")print $2}')
  11. DNSAPI=$(cat /conf/account.conf | awk -F= '{if($1~"DNSAPI")print $2}')
  12. cat >/var/spool/cron/crontabs/root<<EOF
  13. 0 0 10 * * /conf/acme.sh >/dev/null 2>&1
  14. EOF
  15. if [ ! -f "/ssl/${DOMAIN}.cer" ] && [ -n "${DOMAIN}" ]; then
  16. /conf/acme.sh
  17. fi
  18. /entry.sh daemon