From 64eb60ca44a4c5932b140e3cf6605a9d29e04e79 Mon Sep 17 00:00:00 2001 From: Charles Click Date: Mon, 7 Oct 2024 22:37:23 -0400 Subject: [PATCH] Muddler and Web Dockerfile for dev containers --- .woodpecker.yml | 64 +++++++++++++++++++++++++++++++++++++++ Alpine/Muddler/Dockerfile | 8 +++++ Alpine/Web/Dockerfile | 4 +++ 3 files changed, 76 insertions(+) create mode 100644 .woodpecker.yml create mode 100644 Alpine/Muddler/Dockerfile create mode 100644 Alpine/Web/Dockerfile diff --git a/.woodpecker.yml b/.woodpecker.yml new file mode 100644 index 0000000..f7f6b88 --- /dev/null +++ b/.woodpecker.yml @@ -0,0 +1,64 @@ +steps: + - name: build-alpine-python + image: woodpeckerci/plugin-docker-buildx + when: + - event: [ push, pull_request, tag, release ] + - path: + - include: [ 'DockerImages/Alpine/Python/Dockerfile' ] + settings: + repo: git.vertinext.com/roryejinn/DockerImages + platforms: linux/amd64 + registry: git.vertinext.com + tag: git.vertinext.com/roryejinn/Alpine_Python:latest + username: + from_secret: REGISTRY_USERNAME + password: + from_secret: DOCKER_TOKEN + + - name: build-alpine-muddler + image: alpine + when: + - event: [ push, pull_request, tag, release ] + - path: + - include: [ 'DockerImages/Alpine/Muddler/Dockerfile' ] + settings: + repo: git.vertinext.com/roryejinn/DockerImages + platforms: linux/amd64 + registry: git.vertinext.com + tag: git.vertinext.com/roryejinn/Alpine_Muddler:latest + username: + from_secret: REGISTRY_USERNAME + password: + from_secret: DOCKER_TOKEN + + - name: build-alpine-web + image: alpine + when: + - event: [ push, pull_request, tag, release ] + - path: + - include: [ 'DockerImages/Alphine/Web/Dockerfile' ] + settings: + repo: git.vertinext.com/roryejinn/DockerImages + platforms: linux/amd64 + registry: git.vertinext.com + tag: git.vertinext.com/roryejinn/Alpine_Web:latest + username: + from_secret: REGISTRY_USERNAME + password: + from_secret: DOCKER_TOKEN + + - name: notify-on-failure + image: alpine + when: + - status: [ failure ] + commands: + - apk add curl + - curl -H "Authorization: Bearer ${GOTIFY_TOKEN}" -H "Title: ${CI} - ${CI_REPO_NAME}" -H "Tag: warning" -H "Actions: http, Open Build, ${CI_PIPLINE_URL}, clear=true" -d "Failed to build docker images." gotify.vertinext.com/woodpecker + + - name: notify-on-success + image: alpine + when: + - status: [ success ] + commands: + - apk add curl + - curl -H "Authorization: Bearer ${GOTIFY_TOKEN}" -H "Title: ${CI} - ${CI_REPO_NAME}" -H "Tag: package" -H "Actions: http, Open Build, ${CI_PIPLINE_URL}, clear=true" -d "Docker images rebuilt and pushed to the container repository." gotify.vertinext.com/woodpecker diff --git a/Alpine/Muddler/Dockerfile b/Alpine/Muddler/Dockerfile new file mode 100644 index 0000000..23be1f2 --- /dev/null +++ b/Alpine/Muddler/Dockerfile @@ -0,0 +1,8 @@ +# Image meant for use in CICD to generate mudlet package release +# To generate the package, simply run java -jar /muddle/muddle.jar at the root of your muddler project +FROM alpine:latest + +RUN apk add --no-cache openjdk21 wget tar git +RUN apk add --no-cache tea --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community +RUN wget https://github.com/demonnic/muddler/releases/download/0.13/muddle-shadow-0.13.tar +RUN mkdir /muddle && tar -xvf muddle-shadow-0.13.tar && mv muddle-shadow-0.13/lib/muddle-0.13-all.jar muddle/muddle.jar diff --git a/Alpine/Web/Dockerfile b/Alpine/Web/Dockerfile new file mode 100644 index 0000000..0391b12 --- /dev/null +++ b/Alpine/Web/Dockerfile @@ -0,0 +1,4 @@ +FROM alpine:latest + +RUN apk add --no-cache nodejs +RUN apk add --no-cache pnpm --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community