Skip to content

build(deps): Bump node from 20-alpine3.18 to 22-alpine3.18 (#1370) #2007

build(deps): Bump node from 20-alpine3.18 to 22-alpine3.18 (#1370)

build(deps): Bump node from 20-alpine3.18 to 22-alpine3.18 (#1370) #2007

Workflow file for this run

name: Docker
on:
push:
branches:
- main
tags:
- v*
pull_request:
env:
IMAGE_NAME: my-personal-web
jobs:
docker-build:
runs-on: ubuntu-22.04
if: ${{ github.event_name == 'pull_request' }}
steps:
- uses: actions/checkout@v4
- name: Run tests
run: docker build . --file Dockerfile
push:
runs-on: ubuntu-22.04
if: github.event_name == 'push'
steps:
- uses: actions/checkout@v4
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: |
berviantoleo/${{ env.IMAGE_NAME }}
ghcr.io/${{ github.repository }}
- name: Build and push Docker images
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}