Skip to content

Fix/email: 이메일 인증 서비스 OCI 방식 #41

Fix/email: 이메일 인증 서비스 OCI 방식

Fix/email: 이메일 인증 서비스 OCI 방식 #41

Workflow file for this run

name: Deploy to develop Server
on:
push:
branches:
- develop
pull_request:
branches:
- develop
jobs:
deploy:
name: Build and Push to AWS Cloud
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Set up JDK 17
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '17'
- name: set credentials in application.yaml
uses: microsoft/variable-substitution@v1
with:
files: './src/main/resources/application.yaml'
env:
spring.profiles.active: develop
- name: set credentials in application-release.yaml
uses: microsoft/variable-substitution@v1
with:
files: './src/main/resources/application-dev.yaml'
env:
spring.datasource.url: ${{ secrets.MYSQL_DATASOURCE_URL }}
spring.datasource.username: ${{ secrets.MYSQL_DATASOURCE_USERNAME }}
spring.datasource.password: ${{ secrets.MYSQL_DATASOURCE_PASSWORD }}
spring.data.redis.host: ${{ secrets.REDIS_DATASOURCE_HOST }}
spring.data.redis.port: ${{ secrets.REDIS_DATASOURCE_PORT }}
spring.mail.host: ${{ secrets.DEV_MAIL_HOST }}
spring.mail.username: ${{ secrets.DEV_MAIL_USERNAME }}
spring.mail.password: ${{ secrets.DEV_MAIL_PASSWORD }}
spring.mail.from: ${{ secrets.DEV_MAIL_SENDER }}
slack.webhook.url: ${{ secrets.SLACK_WEBHOOK_URL }}
cookie.encode: ${{ secrets.SECRET_KEY }}
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew build
- name: Deploy via SCP
uses: appleboy/[email protected]
with:
host: ${{ secrets.DEV_SERVER_HOST }}
username: ${{ secrets.DEV_SERVER_USERNAME }}
key: ${{ secrets.DEV_PRIVATE_KEY }}
source: './build/libs'
target: ~/project/areyouhere-server
rm: true
- name: Deploy to Server
uses: appleboy/[email protected]
with:
host: ${{ secrets.DEV_SERVER_HOST }}
username: ${{ secrets.DEV_SERVER_USERNAME }}
key: ${{ secrets.DEV_PRIVATE_KEY }}
script: |
cd ~/project
nohup sudo ./build.sh & > build.out