Merge pull request #6 from devops-ia/dependabot/docker/alpine-3.20 #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Manage lifecycle Helm Release Cleaner | |
env: | |
USER: devopsiaci | |
REPO: helm-release-cleaner | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
release: | |
name: Build Helm Release Cleaner | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Run Semantic Release | |
uses: cycjimmy/semantic-release-action@v4 | |
id: semantic | |
with: | |
branches: | | |
[ | |
'main' | |
] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Log in to Docker Hub | |
if: ${{ steps.semantic.outputs.new_release_published == 'true' }} | |
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_PASSWORD }} | |
- name: Build and push Docker image | |
if: ${{ steps.semantic.outputs.new_release_published == 'true' }} | |
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc | |
env: | |
VERSION: ${{ steps.semantic.outputs.new_release_version }} | |
with: | |
context: . | |
push: true | |
tags: | | |
${{ env.USER }}/${{ env.REPO }}:${{ env.VERSION }} | |
${{ env.USER }}/${{ env.REPO }}:latest | |
- name: Update Docker registry description | |
if: ${{ steps.semantic.outputs.new_release_published == 'true' }} | |
uses: peter-evans/dockerhub-description@v4 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_PASSWORD }} | |
repository: ${{ env.USER }}/${{ env.REPO }} |