Skip to content

Merge pull request #900 from projectsyn/renovate/docker.io-alpine-3.x #16

Merge pull request #900 from projectsyn/renovate/docker.io-alpine-3.x

Merge pull request #900 from projectsyn/renovate/docker.io-alpine-3.x #16

Workflow file for this run

name: Build & Push Kapitan Image
on:
workflow_dispatch: {}
push:
branches:
- master
paths:
- tools/Dockerfile.kapitan
jobs:
build:
runs-on: ubuntu-latest
env:
IMAGE: docker.io/projectsyn/kapitan
steps:
- uses: actions/checkout@v4
- name: Set image version
run: |
echo "VERSION=$(grep "KAPITAN_VERSION=" tools/Dockerfile.kapitan | cut -d= -f2)" >> ${GITHUB_ENV}
- name: Build image
run: docker build -f tools/Dockerfile.kapitan -t ${IMAGE}:${VERSION} tools/
- name: Push image
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
run: |
docker login docker.io --username "${DOCKER_USERNAME}" --password "${DOCKER_PASSWORD}"
docker push "${IMAGE}:${VERSION}"