Skip to content

fix: GithubActions Docker build 태그 문제 수정 #6

fix: GithubActions Docker build 태그 문제 수정

fix: GithubActions Docker build 태그 문제 수정 #6

Workflow file for this run

name: Docker Image CI
on:
push:
branches: [ "ci/cd" ]
pull_request:
branches: [ "ci/cd" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Build with Gradle
uses: gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1
with:
arguments: clean build -x test
# Docker build
- name: Docker build
run: |
docker login -u ${{ secrets.DOCKERHUB_USERNAME }} -p ${{ secrets.DOCKERHUB_PASSWORD }}
docker build -t seongwonyoon/wabi .
docker tag wabi seongwonyoon/wabi:${GITHUB_SHA::7}
docker push seongwonyoon/wabi:${GITHUB_SHA::7}