Skip to content

[#11] 경매품 관련 리팩토링 #119

[#11] 경매품 관련 리팩토링

[#11] 경매품 관련 리팩토링 #119

Workflow file for this run

name: docker build & push develop
on:
push:
branches: [ "develop" ]
pull_request:
branches:
- 'develop'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Define Docker metadata before build
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/gyeongnam-gyeongmae/gyeongnam-gyeongmae-api
tags: |
type=schedule
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
type=sha
- name: Install Java
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Grant execute permission for gradlew
run: chmod +x gradlew
shell: bash
- name: Build with Gradle
run: ./gradlew clean build -Pprofile=prod
shell: bash
- name: Set up Docker Buildx (Builder instance)
uses: docker/setup-buildx-action@v2
- name: Login to Github Container Registry for Image Push
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GHCR_TOKEN }}
- name: Build Image and Push
uses: docker/build-push-action@v2
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
platform: linux/amd64/v3
cache-from: type=gha
cache-to: type=gha,mode=max