Initial docker image for webhook deployer
Build webhook-deployer container / Build image (push) Failing after 32s Details

This commit is contained in:
Mathis 2024-03-25 21:47:52 +01:00
parent c8d1fa3247
commit ca945cc4b0
3 changed files with 52 additions and 1 deletions

View File

@ -0,0 +1,28 @@
name: Build webhook-deployer container
on:
push:
branches:
- main
jobs:
build:
name: Build image
runs-on: ubuntu-latest
container: git.namesny.com/cluster/act-runner:v1
env:
IMAGE_NAME: webhook-deployer
REGISTRY: git.namesny.com
REPO_OWNER: cluster
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Login to Registry
uses: docker/login-action@v3
with:
registry: git.namesny.com
username: ${{ gitea.actor }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push
run: |
docker build -t ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:latest .
docker push ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:latest

15
Dockerfile Normal file
View File

@ -0,0 +1,15 @@
FROM alpine:3
RUN apk add --no-cache kubectl kustomize age webhook
# Install sops
ADD https://github.com/getsops/sops/releases/download/v3.8.1/sops-v3.8.1.linux.amd64 /tmp/sops
RUN mv /tmp/sops /usr/local/bin/sops
RUN chmod +x /usr/local/bin/sops
# Install ksops
ADD https://raw.githubusercontent.com/viaduct-ai/kustomize-sops/master/scripts/install-ksops-archive.sh /tmp/install-ksops-archive.sh
RUN chmod +x /tmp/install-ksops-archive.sh
RUN /tmp/install-ksops-archive.sh
ENTRYPOINT ["/usr/local/bin/webhook", "--hooks", "/etc/webhook/hooks.yaml"]

View File

@ -1,2 +1,10 @@
# webhook-deployer
# Webhook Deployer
Docker container with:
- [webhooks](https://github.com/adnanh/webhook)
- [kubectl](https://github.com/kubernetes/kubectl)
- [kustomize](https://github.com/kubernetes-sigs/kustomize)
- [age](https://github.com/FiloSottile/age)
- [sops](https://github.com/getsops/sops)
- [ksops](https://github.com/viaduct-ai/kustomize-sops)