Skip to content

Commit

Permalink
dockerをbuildするworkflowを追加
Browse files Browse the repository at this point in the history
  • Loading branch information
piny940 committed Dec 10, 2023
1 parent 923d0ea commit 15c474e
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Docker Image Build
on:
push:
branches:
- main
workflow_dispatch:

jobs:
frontend:
runs-on: ubuntu-latest
steps:
- name: Check out
uses: actions/checkout@v3

- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: piny940
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push Docker images
uses: docker/build-push-action@v5
with:
push: true
context: .
file: Dockerfile
tags: |
ghcr.io/piny940/portfolio:v1.0.0-${{ github.sha }}-${{ github.run_number }}
ghcr.io/piny940/portfolio:latest

0 comments on commit 15c474e

Please sign in to comment.