Skip to content

Commit

Permalink
add :: CD.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
jyk1029 committed Jan 20, 2024
1 parent 952607a commit 0f82e4e
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/CD.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: CD

on:
push:
branches: [ "main" ]

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Check Out The Repository
uses: actions/checkout@v3

- name: Set up Java
uses: actions/setup-java@v2
with:
java-version: 11
distribution: 'adopt'

- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew build --info
- name: check gradle
run: ./gradlew check

- name: Login to Dockerhub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Docker Build
run: docker build -t jyk1029/boheom .

- name: Push on Dockerhub
run: docker push jyk1029/boheom

0 comments on commit 0f82e4e

Please sign in to comment.