This is the Porkbun DDNS Python API wrapped into a lightweight, multiplattform docker image based on the Official Python 3 Alpine Docker Image.
For an in depth explanation on how the API works or how to get started, please consider the official getting started guide, the official porkbun repository or the official API documentation.
version: "3"
services:
porkbunddns:
image: pavlinchen/porkbun-ddns
container_name: porkbun-ddns
restart: always
pull_policy: always
environment:
APIKey: <YourAPIKey>
SecretAPIKey: <YourSecretAPIKey>
Domain: <YourDomain>
Schedule: <YourSchedule (in cron syntax)> #optional
TZ: <YourTimezone> #optional
docker run -d \
-e APIKey='<YourAPIKey>' \
-e SecretAPIKey='<YourSecretAPIKey>' \
-e Domain='<YourDomain>' \
-e Schedule='<YourSchedule (cron syntax)>' \
-e TZ='<YourTimezone>' \
--pull=always \
--restart always \
--name porkbun-ddns \
pavlinchen/porkbun-ddns
git clone https://github.com/Pavlinchen/Porkbun-DDNS-Docker
cd Porkbun-DDNS-Docker
docker build . -t porkbun-ddns
Argument | description | example | default | optional |
---|---|---|---|---|
APIKey |
The API key provided to you by porkbun | pk1_abcdef123456 | None | no |
SecretAPIKey |
The secret API key provided to you by porkbun | sk1_abcdef123456 | None | no |
Domain |
The Domain you want to map to your IP adress, as seen here | google.com domains (would be domains.google.com) |
None | no |
Schedule |
Schedule to execute the script to sync DNS A records with your IP address in cron format | */10 * * * * (every 10 minutes) |
*/5 * * * * (every 5 minutes) |
yes |
TZ |
Your Timezone as tz database name (only really needed, if used in schedule) |
Europe/Berlin | UTC | yes |