Skip to content

👷[Ci]:GitHub Actions, Docker 배포 관련 #4

👷[Ci]:GitHub Actions, Docker 배포 관련

👷[Ci]:GitHub Actions, Docker 배포 관련 #4

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
name: Java CI with Gradle
on:
push:
branches: [ "develop", "feat/*", "cicd/*", "fix/*", "hotfix/*", "refactor/*", "chore/*", "docs/*", "style/*", "test/*" ]
pull_request:
branches: [ "develop", "feat/*", "cicd/*", "fix/*", "hotfix/*", "refactor/*", "chore/*", "docs/*", "style/*", "test/*" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
# Spring Boot 어플리케이션 Build (1)
- name: Spring Boot Build
run: ./gradlew
# Docker 이미지 Build (2)
- name: docker image build
run: docker build -t rimi3226/gamegoo .
# DockerHub Login (3)
- name: docker login
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
# Docker Hub push (4)
- name: docker Hub push
run: docker push rimi3226/gamegoo