Remove ddclient in favour of duckdns
This commit is contained in:
@@ -1,19 +0,0 @@
|
||||
daemon=300 # check every 300 seconds
|
||||
syslog=yes # log update msgs to syslog
|
||||
pid=/var/run/ddclient/ddclient.pid # record PID in file.
|
||||
ssl=yes # use ssl-support. Works with
|
||||
# ssl-library
|
||||
postscript=/data/postscript_gotify.sh # run script after updating. The
|
||||
# new IP is added as argument.
|
||||
use=web
|
||||
web=googledomains
|
||||
|
||||
##
|
||||
## CloudFlare (www.cloudflare.com)
|
||||
##
|
||||
protocol=cloudflare, \
|
||||
zone=dedicated.contact, \
|
||||
ttl=1, \
|
||||
login=token, \
|
||||
password=$CLOUDFLARE_TOKEN \
|
||||
$CLOUDFLARE_DOMAIN
|
||||
@@ -1,5 +0,0 @@
|
||||
Contains the file `gotify_token`
|
||||
Loadded in the postscript_gotify.sh to send a notification when a new IP is found
|
||||
|
||||
Contains the file `clourflare_token`
|
||||
Token required to access the DNS API of cloudflare
|
||||
1
services/ddclient/volumes/data/.gitignore
vendored
1
services/ddclient/volumes/data/.gitignore
vendored
@@ -1 +0,0 @@
|
||||
!postscript_gotify.sh
|
||||
@@ -1,12 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ "$(cat /data/gotify_previous_ip || true)" != "$1" ]; then
|
||||
echo -n "$1" > /data/gotify_previous_ip
|
||||
|
||||
curl -s "${GOTIFY_ADDRESS%/}/message" \
|
||||
-X POST \
|
||||
-H "X-Gotify-Key: $GOTIFY_TOKEN" \
|
||||
-F "title=IP Address updated" \
|
||||
-F "message=IP address detected as $1" \
|
||||
-F "priority=5"
|
||||
fi
|
||||
1
services/ddclient/volumes/init/.gitignore
vendored
1
services/ddclient/volumes/init/.gitignore
vendored
@@ -1 +0,0 @@
|
||||
!fill_template.sh
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/bin/bash
|
||||
apk add --update gettext
|
||||
envsubst < /config/ddclient.conf.tpl > /ddclient.conf
|
||||
@@ -31,31 +31,10 @@ services:
|
||||
duckdns:
|
||||
image: linuxserver/duckdns
|
||||
environment:
|
||||
- FILE__SUBDOMAINS=subdomain1,subdomain2
|
||||
- FILE__TOKEN=token
|
||||
restart: unless-stopped
|
||||
|
||||
ddclient:
|
||||
image: linuxserver/ddclient
|
||||
environment:
|
||||
GOTIFY_ADDRESS: http://gotify
|
||||
FILE__GOTIFY_TOKEN: /run/secrets/gotify_token
|
||||
CLOUDFLARE_DOMAIN: ${DDCLIENT_CLOUDFLARE_DOMAIN-test.dedicated.contact}
|
||||
FILE__CLOUDFLARE_TOKEN: /run/secrets/cloudflare_token
|
||||
networks:
|
||||
- gotify
|
||||
volumes:
|
||||
- ddclient_data:/data/
|
||||
- ddclient_config:/config/
|
||||
- ddclient_init:/config/custom-cont-init.d/:ro #TODO: Move to /custom-cont-init.d/
|
||||
configs:
|
||||
- source: ddclient_config_tpl
|
||||
target: /config/ddclient.conf.tpl
|
||||
- SUBDOMAINS=${DUCK_DNS_DOMAIN?}
|
||||
- FILE__TOKEN=/run/secrets/duckdns_token
|
||||
secrets:
|
||||
- source: ddclient_gotify_token
|
||||
target: gotify_token
|
||||
- source: ddclient_cloudflare_token
|
||||
target: cloudflare_token
|
||||
- duckdns_token
|
||||
restart: unless-stopped
|
||||
|
||||
networks:
|
||||
@@ -100,7 +79,5 @@ configs:
|
||||
secrets:
|
||||
watchtower_gotify_token:
|
||||
file: ${SERVICES_DIR?}/watchtower/secrets/gotify_token
|
||||
ddclient_gotify_token:
|
||||
file: ${SERVICES_DIR?}/ddclient/secrets/gotify_token
|
||||
ddclient_cloudflare_token:
|
||||
file: ${SERVICES_DIR?}/ddclient/secrets/cloudflare_token
|
||||
duckdns_token:
|
||||
file: ${SERVICES_DIR?}/ddclient/secrets/duckdns_token
|
||||
|
||||
Reference in New Issue
Block a user