mirror of
https://github.com/linuxserver/docker-ddclient.git
synced 2026-02-20 03:15:49 +08:00
Merge pull request #64 from linuxserver/3.17
This commit is contained in:
commit
93af217d81
@ -15,6 +15,6 @@ trim_trailing_whitespace = false
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[{**.sh,root/etc/cont-init.d/**,root/etc/services.d/**}]
|
||||
[{**.sh,root/etc/s6-overlay/s6-rc.d/**,root/etc/cont-init.d/**,root/etc/services.d/**}]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
12
.github/workflows/call_invalid_helper.yml
vendored
Normal file
12
.github/workflows/call_invalid_helper.yml
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
name: Comment on invalid interaction
|
||||
on:
|
||||
issues:
|
||||
types:
|
||||
- labeled
|
||||
jobs:
|
||||
add-comment-on-invalid:
|
||||
if: github.event.label.name == 'invalid'
|
||||
permissions:
|
||||
issues: write
|
||||
uses: linuxserver/github-workflows/.github/workflows/invalid-interaction-helper.yml@v1
|
||||
secrets: inherit
|
||||
2
.github/workflows/greetings.yml
vendored
2
.github/workflows/greetings.yml
vendored
@ -8,6 +8,6 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/first-interaction@v1
|
||||
with:
|
||||
issue-message: 'Thanks for opening your first issue here! Be sure to follow the [bug](https://github.com/linuxserver/docker-ddclient/blob/master/.github/ISSUE_TEMPLATE/issue.bug.yml) or [feature](https://github.com/linuxserver/docker-ddclient/blob/master/.github/ISSUE_TEMPLATE/issue.feature.yml) issue templates!'
|
||||
issue-message: 'Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.'
|
||||
pr-message: 'Thanks for opening this pull request! Be sure to follow the [pull request template](https://github.com/linuxserver/docker-ddclient/blob/master/.github/PULL_REQUEST_TEMPLATE.md)!'
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
9
.github/workflows/permissions.yml
vendored
Normal file
9
.github/workflows/permissions.yml
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
name: Permission check
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
- '**/run'
|
||||
- '**/finish'
|
||||
jobs:
|
||||
permission_check:
|
||||
uses: linuxserver/github-workflows/.github/workflows/init-svc-executable-permissions.yml@v1
|
||||
@ -1,4 +1,6 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine:3.15
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine:3.17
|
||||
|
||||
# set version label
|
||||
ARG BUILD_DATE
|
||||
@ -10,17 +12,13 @@ LABEL maintainer="saarg"
|
||||
RUN \
|
||||
echo "**** install build packages ****" && \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
bzip2 \
|
||||
gcc \
|
||||
make \
|
||||
tar \
|
||||
wget && \
|
||||
echo "**** install runtime packages ****" && \
|
||||
apk add --no-cache \
|
||||
bind-tools \
|
||||
curl \
|
||||
inotify-tools \
|
||||
jq \
|
||||
perl \
|
||||
perl-digest-sha1 \
|
||||
perl-io-socket-inet6 \
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.12
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.17
|
||||
|
||||
# set version label
|
||||
ARG BUILD_DATE
|
||||
@ -10,17 +12,13 @@ LABEL maintainer="saarg"
|
||||
RUN \
|
||||
echo "**** install build packages ****" && \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
bzip2 \
|
||||
gcc \
|
||||
make \
|
||||
tar \
|
||||
wget && \
|
||||
echo "**** install runtime packages ****" && \
|
||||
apk add --no-cache \
|
||||
bind-tools \
|
||||
curl \
|
||||
inotify-tools \
|
||||
jq \
|
||||
perl \
|
||||
perl-digest-sha1 \
|
||||
perl-io-socket-inet6 \
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine:arm32v7-3.12
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM ghcr.io/linuxserver/baseimage-alpine:arm32v7-3.17
|
||||
|
||||
# set version label
|
||||
ARG BUILD_DATE
|
||||
@ -10,17 +12,13 @@ LABEL maintainer="saarg"
|
||||
RUN \
|
||||
echo "**** install build packages ****" && \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
bzip2 \
|
||||
gcc \
|
||||
make \
|
||||
tar \
|
||||
wget && \
|
||||
echo "**** install runtime packages ****" && \
|
||||
apk add --no-cache \
|
||||
bind-tools \
|
||||
curl \
|
||||
inotify-tools \
|
||||
jq \
|
||||
perl \
|
||||
perl-digest-sha1 \
|
||||
perl-io-socket-inet6 \
|
||||
|
||||
26
Jenkinsfile
vendored
26
Jenkinsfile
vendored
@ -59,7 +59,7 @@ pipeline {
|
||||
env.CODE_URL = 'https://github.com/' + env.LS_USER + '/' + env.LS_REPO + '/commit/' + env.GIT_COMMIT
|
||||
env.DOCKERHUB_LINK = 'https://hub.docker.com/r/' + env.DOCKERHUB_IMAGE + '/tags/'
|
||||
env.PULL_REQUEST = env.CHANGE_ID
|
||||
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE .editorconfig ./.github/CONTRIBUTING.md ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE/config.yml ./.github/ISSUE_TEMPLATE/issue.bug.yml ./.github/ISSUE_TEMPLATE/issue.feature.yml ./.github/PULL_REQUEST_TEMPLATE.md ./.github/workflows/external_trigger_scheduler.yml ./.github/workflows/greetings.yml ./.github/workflows/package_trigger_scheduler.yml ./.github/workflows/stale.yml ./.github/workflows/external_trigger.yml ./.github/workflows/package_trigger.yml'
|
||||
env.TEMPLATED_FILES = 'Jenkinsfile README.md LICENSE .editorconfig ./.github/CONTRIBUTING.md ./.github/FUNDING.yml ./.github/ISSUE_TEMPLATE/config.yml ./.github/ISSUE_TEMPLATE/issue.bug.yml ./.github/ISSUE_TEMPLATE/issue.feature.yml ./.github/PULL_REQUEST_TEMPLATE.md ./.github/workflows/external_trigger_scheduler.yml ./.github/workflows/greetings.yml ./.github/workflows/package_trigger_scheduler.yml ./.github/workflows/stale.yml ./.github/workflows/call_invalid_helper.yml ./.github/workflows/permissions.yml ./.github/workflows/external_trigger.yml ./.github/workflows/package_trigger.yml'
|
||||
}
|
||||
script{
|
||||
env.LS_RELEASE_NUMBER = sh(
|
||||
@ -815,19 +815,19 @@ pipeline {
|
||||
echo $QUAYPASS | docker login quay.io -u $QUAYUSER --password-stdin
|
||||
if [ "${CI}" == "false" ]; then
|
||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm32v7-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm32v7-${META_TAG}
|
||||
docker pull ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER}
|
||||
docker tag ghcr.io/linuxserver/lsiodev-buildcache:arm64v8-${COMMIT_SHA}-${BUILD_NUMBER} ${IMAGE}:arm64v8-${META_TAG}
|
||||
fi
|
||||
for MANIFESTIMAGE in "${IMAGE}" "${GITLABIMAGE}" "${GITHUBIMAGE}" "${QUAYIMAGE}"; do
|
||||
docker tag ${IMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${META_TAG}
|
||||
docker tag ${IMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG}
|
||||
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-latest
|
||||
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-latest
|
||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-latest
|
||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
||||
docker tag ${IMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${META_TAG}
|
||||
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-latest
|
||||
docker tag ${MANIFESTIMAGE}:arm32v7-${META_TAG} ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG}
|
||||
docker tag ${IMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-latest
|
||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
||||
if [ -n "${SEMVER}" ]; then
|
||||
docker tag ${MANIFESTIMAGE}:amd64-${META_TAG} ${MANIFESTIMAGE}:amd64-${SEMVER}
|
||||
@ -835,13 +835,13 @@ pipeline {
|
||||
docker tag ${MANIFESTIMAGE}:arm64v8-${META_TAG} ${MANIFESTIMAGE}:arm64v8-${SEMVER}
|
||||
fi
|
||||
docker push ${MANIFESTIMAGE}:amd64-${META_TAG}
|
||||
docker push ${MANIFESTIMAGE}:arm32v7-${META_TAG}
|
||||
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||
docker push ${MANIFESTIMAGE}:amd64-latest
|
||||
docker push ${MANIFESTIMAGE}:arm32v7-latest
|
||||
docker push ${MANIFESTIMAGE}:arm64v8-latest
|
||||
docker push ${MANIFESTIMAGE}:amd64-${EXT_RELEASE_TAG}
|
||||
docker push ${MANIFESTIMAGE}:amd64-latest
|
||||
docker push ${MANIFESTIMAGE}:arm32v7-${META_TAG}
|
||||
docker push ${MANIFESTIMAGE}:arm32v7-latest
|
||||
docker push ${MANIFESTIMAGE}:arm32v7-${EXT_RELEASE_TAG}
|
||||
docker push ${MANIFESTIMAGE}:arm64v8-${META_TAG}
|
||||
docker push ${MANIFESTIMAGE}:arm64v8-latest
|
||||
docker push ${MANIFESTIMAGE}:arm64v8-${EXT_RELEASE_TAG}
|
||||
if [ -n "${SEMVER}" ]; then
|
||||
docker push ${MANIFESTIMAGE}:amd64-${SEMVER}
|
||||
@ -987,12 +987,12 @@ pipeline {
|
||||
sh 'echo "build aborted"'
|
||||
}
|
||||
else if (currentBuild.currentResult == "SUCCESS"){
|
||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://wiki.jenkins-ci.org/download/attachments/2916393/headshot.png","embeds": [{"color": 1681177,\
|
||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"color": 1681177,\
|
||||
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** Success\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
||||
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
||||
}
|
||||
else {
|
||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://wiki.jenkins-ci.org/download/attachments/2916393/headshot.png","embeds": [{"color": 16711680,\
|
||||
sh ''' curl -X POST -H "Content-Type: application/json" --data '{"avatar_url": "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/jenkins-avatar.png","embeds": [{"color": 16711680,\
|
||||
"description": "**Build:** '${BUILD_NUMBER}'\\n**CI Results:** '${CI_URL}'\\n**ShellCheck Results:** '${SHELLCHECK_URL}'\\n**Status:** failure\\n**Job:** '${RUN_DISPLAY_URL}'\\n**Change:** '${CODE_URL}'\\n**External Release:**: '${RELEASE_LINK}'\\n**DockerHub:** '${DOCKERHUB_LINK}'\\n"}],\
|
||||
"username": "Jenkins"}' ${BUILDS_DISCORD} '''
|
||||
}
|
||||
|
||||
14
README.md
14
README.md
@ -56,7 +56,7 @@ The architectures supported by this image are:
|
||||
| :----: | :----: | ---- |
|
||||
| x86-64 | ✅ | amd64-\<version tag\> |
|
||||
| arm64 | ✅ | arm64v8-\<version tag\> |
|
||||
| armhf| ✅ | arm32v7-\<version tag\> |
|
||||
| armhf | ✅ | arm32v7-\<version tag\> |
|
||||
|
||||
## Application Setup
|
||||
|
||||
@ -84,9 +84,9 @@ services:
|
||||
environment:
|
||||
- PUID=1000
|
||||
- PGID=1000
|
||||
- TZ=Europe/London
|
||||
- TZ=Etc/UTC
|
||||
volumes:
|
||||
- <path to data>:/config
|
||||
- /path/to/data:/config
|
||||
restart: unless-stopped
|
||||
```
|
||||
|
||||
@ -97,10 +97,11 @@ docker run -d \
|
||||
--name=ddclient \
|
||||
-e PUID=1000 \
|
||||
-e PGID=1000 \
|
||||
-e TZ=Europe/London \
|
||||
-v <path to data>:/config \
|
||||
-e TZ=Etc/UTC \
|
||||
-v /path/to/data:/config \
|
||||
--restart unless-stopped \
|
||||
lscr.io/linuxserver/ddclient:latest
|
||||
|
||||
```
|
||||
|
||||
## Parameters
|
||||
@ -111,7 +112,7 @@ Container images are configured using parameters passed at runtime (such as thos
|
||||
| :----: | --- |
|
||||
| `-e PUID=1000` | for UserID - see below for explanation |
|
||||
| `-e PGID=1000` | for GroupID - see below for explanation |
|
||||
| `-e TZ=Europe/London` | Specify a timezone to use EG Europe/London. |
|
||||
| `-e TZ=Etc/UTC` | specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List). |
|
||||
| `-v /config` | Where ddclient should store its config files. |
|
||||
|
||||
## Environment variables from files (Docker secrets)
|
||||
@ -223,6 +224,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
|
||||
|
||||
## Versions
|
||||
|
||||
* **13.02.23:** - Rebase to Alpine 3.17, migrate to s6v3.
|
||||
* **20.10.22:** - Update build instructions for 3.10.0. Update default `ddclient.conf`.
|
||||
* **15.01.22:** - Rebase to Alpine 3.15
|
||||
* **15.05.21:** - Distribute script 'sample-get-ip-from-fritzbox' from ddclient repo
|
||||
|
||||
@ -26,7 +26,7 @@ param_env_vars:
|
||||
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London." }
|
||||
param_usage_include_vols: true
|
||||
param_volumes:
|
||||
- { vol_path: "/config", vol_host_path: "<path to data>", desc: "Where ddclient should store its config files." }
|
||||
- { vol_path: "/config", vol_host_path: "/path/to/data", desc: "Where ddclient should store its config files." }
|
||||
param_usage_include_ports: false
|
||||
param_device_map: false
|
||||
cap_add_param: false
|
||||
@ -52,6 +52,7 @@ app_setup_block: |
|
||||
|
||||
# changelog
|
||||
changelogs:
|
||||
- { date: "13.02.23:", desc: "Rebase to Alpine 3.17, migrate to s6v3." }
|
||||
- { date: "20.10.22:", desc: "Update build instructions for 3.10.0. Update default `ddclient.conf`." }
|
||||
- { date: "15.01.22:", desc: "Rebase to Alpine 3.15" }
|
||||
- { date: "15.05.21:", desc: "Distribute script 'sample-get-ip-from-fritzbox' from ddclient repo" }
|
||||
|
||||
6
root/etc/cont-init.d/30-config → root/etc/s6-overlay/s6-rc.d/init-ddclient-config/run
Normal file → Executable file
6
root/etc/cont-init.d/30-config → root/etc/s6-overlay/s6-rc.d/init-ddclient-config/run
Normal file → Executable file
@ -1,4 +1,5 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
# shellcheck shell=bash
|
||||
|
||||
# make our folders
|
||||
mkdir -p \
|
||||
@ -6,14 +7,15 @@ mkdir -p \
|
||||
/var/run/ddclient
|
||||
|
||||
# copy default config if not present in /config
|
||||
[[ ! -e /config/ddclient.conf ]] && \
|
||||
if [[ ! -e /config/ddclient.conf ]]; then
|
||||
cp /defaults/ddclient.conf /config
|
||||
fi
|
||||
|
||||
# copy config from /config to root
|
||||
cp /config/ddclient.conf /ddclient.conf
|
||||
|
||||
# permissions
|
||||
chown -R abc:abc \
|
||||
lsiown -R abc:abc \
|
||||
/config \
|
||||
/var/cache/ddclient \
|
||||
/var/run/ddclient \
|
||||
1
root/etc/s6-overlay/s6-rc.d/init-ddclient-config/type
Normal file
1
root/etc/s6-overlay/s6-rc.d/init-ddclient-config/type
Normal file
@ -0,0 +1 @@
|
||||
oneshot
|
||||
1
root/etc/s6-overlay/s6-rc.d/init-ddclient-config/up
Normal file
1
root/etc/s6-overlay/s6-rc.d/init-ddclient-config/up
Normal file
@ -0,0 +1 @@
|
||||
/etc/s6-overlay/s6-rc.d/init-ddclient-config/run
|
||||
5
root/etc/s6-overlay/s6-rc.d/svc-ddclient/run
Executable file
5
root/etc/s6-overlay/s6-rc.d/svc-ddclient/run
Executable file
@ -0,0 +1,5 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
# shellcheck shell=bash
|
||||
|
||||
exec \
|
||||
s6-setuidgid abc /usr/bin/ddclient -foreground -file /ddclient.conf
|
||||
1
root/etc/s6-overlay/s6-rc.d/svc-ddclient/type
Normal file
1
root/etc/s6-overlay/s6-rc.d/svc-ddclient/type
Normal file
@ -0,0 +1 @@
|
||||
longrun
|
||||
11
root/etc/s6-overlay/s6-rc.d/svc-inotify/run
Executable file
11
root/etc/s6-overlay/s6-rc.d/svc-inotify/run
Executable file
@ -0,0 +1,11 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
# shellcheck shell=bash
|
||||
|
||||
# starting inotify to watch /config/ddclient.conf and restart ddclient if changed.
|
||||
while inotifywait -e modify /config/ddclient.conf; do
|
||||
cp /config/ddclient.conf /ddclient.conf
|
||||
lsiown abc:abc /ddclient.conf
|
||||
chmod 600 /ddclient.conf
|
||||
s6-svc -h /run/service/svc-ddclient
|
||||
echo "ddclient has been restarted"
|
||||
done
|
||||
1
root/etc/s6-overlay/s6-rc.d/svc-inotify/type
Normal file
1
root/etc/s6-overlay/s6-rc.d/svc-inotify/type
Normal file
@ -0,0 +1 @@
|
||||
longrun
|
||||
@ -1,3 +0,0 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
exec \
|
||||
s6-setuidgid abc /usr/bin/ddclient -foreground -file /ddclient.conf
|
||||
@ -1,10 +0,0 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
# starting inotify to watch /config/ddclient.conf and restart ddclient if changed.
|
||||
while inotifywait -e modify /config/ddclient.conf; do
|
||||
cp /config/ddclient.conf /ddclient.conf
|
||||
chown abc:abc /ddclient.conf
|
||||
chmod 600 /ddclient.conf
|
||||
s6-svc -h /var/run/s6/services/ddclient
|
||||
echo "ddclient has been restarted"
|
||||
done
|
||||
Loading…
x
Reference in New Issue
Block a user