From b0325587abab965767d42165392bcd4d933b1d88 Mon Sep 17 00:00:00 2001 From: Axel Rindle Date: Thu, 9 Jan 2025 20:56:07 +0100 Subject: [PATCH] feat: add nextcloud push-server image --- ...r-janus.yml => docker-nextcloud-janus.yml} | 2 +- .../docker-nextcloud-push-server.yml | 26 +++++++++++++++++++ .../janus/Dockerfile | 0 nextcloud/push-server/Dockerfile | 19 ++++++++++++++ 4 files changed, 46 insertions(+), 1 deletion(-) rename .github/workflows/{docker-janus.yml => docker-nextcloud-janus.yml} (94%) create mode 100644 .github/workflows/docker-nextcloud-push-server.yml rename spreed/janus.Dockerfile => nextcloud/janus/Dockerfile (100%) create mode 100644 nextcloud/push-server/Dockerfile diff --git a/.github/workflows/docker-janus.yml b/.github/workflows/docker-nextcloud-janus.yml similarity index 94% rename from .github/workflows/docker-janus.yml rename to .github/workflows/docker-nextcloud-janus.yml index 9b84819..a21863c 100644 --- a/.github/workflows/docker-janus.yml +++ b/.github/workflows/docker-nextcloud-janus.yml @@ -5,7 +5,7 @@ on: branches: - main paths: - - spreed/**/* + - nextcloud/janus/**/* workflow_dispatch: permissions: diff --git a/.github/workflows/docker-nextcloud-push-server.yml b/.github/workflows/docker-nextcloud-push-server.yml new file mode 100644 index 0000000..099238e --- /dev/null +++ b/.github/workflows/docker-nextcloud-push-server.yml @@ -0,0 +1,26 @@ +name: Build Nextcloud Push Server Image + +on: + push: + branches: + - main + paths: + - nextcloud/push-server/**/* + workflow_dispatch: + +permissions: + contents: read + packages: write + +jobs: + push-server: + uses: ./.github/workflows/docker.yml + with: + dockerfile: spreed/push.Dockerfile + context: spreed + tag: spreed:push-${{ vars.SPREED_PUSH_VERSION }} + args: | + JANUS_VERSION=${{ vars.SPREED_PUSH_VERSION }} + labels: | + org.opencontainers.image.description=Update notifications for nextcloud clients + platforms: linux/amd64,linux/arm64 diff --git a/spreed/janus.Dockerfile b/nextcloud/janus/Dockerfile similarity index 100% rename from spreed/janus.Dockerfile rename to nextcloud/janus/Dockerfile diff --git a/nextcloud/push-server/Dockerfile b/nextcloud/push-server/Dockerfile new file mode 100644 index 0000000..865d39e --- /dev/null +++ b/nextcloud/push-server/Dockerfile @@ -0,0 +1,19 @@ +ARG PUSH_VERSION=0.7.0 + +FROM rust:1-alpine AS build + +ADD https://github.com/nextcloud/notify_push#v${PUSH_VERSION} /usr/local/src + +WORKDIR /usr/local/src + +RUN apk add --no-cache \ + musl-dev \ + && \ + cargo build --release + + +FROM alpine:3 + +COPY --from=build /usr/local/src/result/bin/notify_push /usr/local/bin/notify_push + +CMD [ "/usr/local/bin/notify_push", "--no-ansi", "--port", "1337", "--bind", "0.0.0.0" ]