Added base documentation and caddy-duckdns Dockerfile

This commit is contained in:
syrell 2023-12-16 16:46:43 +01:00
commit 23ad2a7881
Signed by: syrell
GPG Key ID: BC9570E849334AF9
2 changed files with 38 additions and 0 deletions

30
README.adoc Normal file
View File

@ -0,0 +1,30 @@
= Docker
This repository contains custom Dockerfiles whose images will be stored on this Gitea container registry.
== How to use
To use the container registry you must login using your credentials. If you have enabled two-factors authentication, you will need to create an application token with repository read access. More informations on https://docs.gitea.com/usage/packages/container[Gitea documentation].
[source,shell]
----
docker login git.syyrell.com
docker pull git.syyrell.com/{owner}/{image}:{tag}
docker push git.syyrell.com/{owner}/{image}:{tag}
----
== Dockerfiles available
=== caddy-duckdns.Dockerfile
Caddy base image with https://github.com/caddy-dns/duckdns[duckdns module] added. There is a `VERSION` variable required to chose which Caddy version to use.
[source,shell]
----
docker build --build-arg VERSION=2.7.6 -f ./caddy-duckdns.Dockerfile -t caddy-duckdns:2.7.6 .
----
Existing pre-built images :
* git.syyrell.com/syrell/caddy-duckdns:2.7.6

8
caddy-duckdns.Dockerfile Normal file
View File

@ -0,0 +1,8 @@
ARG VERSION=latest
FROM caddy:${VERSION}-builder AS builder
RUN xcaddy build \
--with github.com/caddy-dns/duckdns
FROM caddy:${VERSION}
COPY --from=builder /usr/bin/caddy /usr/bin/caddy