Skip to content

Merge pull request #398 from 515hikaru/dependabot/npm_and_yarn/eslint… #238

Merge pull request #398 from 515hikaru/dependabot/npm_and_yarn/eslint…

Merge pull request #398 from 515hikaru/dependabot/npm_and_yarn/eslint… #238

on:
push:
branches:
- main
name: Docker Build and Push
jobs:
publish_docker_image:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build Docker Image
run: |
docker build --tag ghcr.io/$GITHUB_ACTOR/pnovel:latest \
--tag ghcr.io/$GITHUB_ACTOR/pnovel:$(echo $GITHUB_SHA | head -c7) \
.
- name: Push Docker Image
run: |
docker push ghcr.io/$GITHUB_ACTOR/pnovel:latest
docker push ghcr.io/$GITHUB_ACTOR/pnovel:$(echo $GITHUB_SHA | head -c7)