Skip to content

fix: 🔧 Fix setup helm action #9

fix: 🔧 Fix setup helm action

fix: 🔧 Fix setup helm action #9

name: Container Image
on:
push:
branches:
- main
- dev
tags:
- "*"
env:
REGISTRY: ghcr.io
IMAGE_NAME: sintef/www-redirector
jobs:
build-and-push-image:
name: Build and push container image
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Check out repo
uses: actions/checkout@v3
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for pre process image
id: meta
uses: docker/metadata-action@v4
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
- name: Build and push
uses: docker/build-push-action@v3
with:
context: ./
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}