diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 273cd90..7805e8e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -7,6 +7,26 @@ variables: DOCKER_BUILDKIT: 1 +dev-watchdog: + stage: build + tags: + - docker + script: + - make watchdog-nopush + only: + variables: + - $CI_COMMIT_REF_PROTECTED == "false" + +watchdog: + stage: build + tags: + - docker + script: + - make watchdog + only: + variables: + - $CI_COMMIT_REF_PROTECTED == "true" + dev-unifi: stage: build tags: diff --git a/Makefile b/Makefile index b52e73e..363c391 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ .DEFAULT: all -.PHONY: mc keycloak pgadmin4 unifi +.PHONY: mc keycloak pgadmin4 unifi watchdog all: mc keycloak pgadmin4 unifi diff --git a/watchdog/.version b/watchdog/.version new file mode 100644 index 0000000..66a9474 --- /dev/null +++ b/watchdog/.version @@ -0,0 +1 @@ +VERSION=5.15-2 diff --git a/watchdog/Dockerfile b/watchdog/Dockerfile new file mode 100644 index 0000000..076e53e --- /dev/null +++ b/watchdog/Dockerfile @@ -0,0 +1,8 @@ +FROM debian:buster-20200803-slim +ARG DEBIAN_FRONTEND=noninteractive +ARG VERSION +RUN apt update -qq && \ + apt install -qqy --no-install-recommends watchdog=$VERSION && \ + rm -rf /var/lib/apt/lists/* + +ENTRYPOINT ["/usr/sbin/watchdog", "-F"] diff --git a/watchdog/Makefile b/watchdog/Makefile new file mode 100644 index 0000000..b23b95b --- /dev/null +++ b/watchdog/Makefile @@ -0,0 +1,13 @@ +include watchdog/.version + +watchdog-nopush: + docker buildx build --platform linux/amd64 --load \ + --build-arg MC_VERSION=$(VERSION) \ + --tag alemairebe/watchdog:$(VERSION) watchdog + +watchdog: + docker buildx build --platform linux/amd64,linux/arm64,linux/arm,linux/ppc64le --push \ + --build-arg MC_VERSION=$(VERSION) \ + --cache-from=type=registry,ref=alemairebe/watchdog \ + --cache-to=type=registry,ref=alemairebe/watchdog \ + --tag alemairebe/watchdog:$(VERSION) watchdog