From 9135706ac07ec4c178b382a967dad469abe28549 Mon Sep 17 00:00:00 2001 From: Bryan Joshua Pedini Date: Fri, 29 Sep 2023 22:58:48 +0200 Subject: [PATCH] coredns deployment --- .gitignore | 2 ++ docker-compose.yml | 19 +++++++++++++++++++ example.env | 11 +++++++++++ 3 files changed, 32 insertions(+) create mode 100644 .gitignore create mode 100644 docker-compose.yml create mode 100644 example.env diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..fb58dee --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +.env +data diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..e0e76e1 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,19 @@ +--- +services: + coredns: + image: ${CDNS_REPO}:${CDNS_VERSION} + restart: unless-stopped + command: -conf /data/config/Corefile + labels: + ### Section Diun + - diun.enable=${DIUN_ENABLE} + - diun.watch_repo=${DIUN_WATCHREPO} + - diun.sort_tags=${DIUN_SORTALGO} + - diun.include_tags=${DIUN_INCLUDE} + - diun.exclude_tags=${DIUN_EXCLUDE} + ports: + - 53:53/tcp + - 53:53/udp + volumes: + - ${CDNS_DATA}/config:/data/config + - ${CDNS_DATA}/zones:/data/zones diff --git a/example.env b/example.env new file mode 100644 index 0000000..a7136b9 --- /dev/null +++ b/example.env @@ -0,0 +1,11 @@ +# CoreDNS +CDNS_REPO=coredns/coredns +CDNS_VERSION=1.11.1 +CDNS_DATA=./data + +# Diun +DIUN_ENABLE=true +DIUN_WATCHREPO=true +DIUN_SORTALGO=semver +DIUN_INCLUDE= +DIUN_EXCLUDE=