Skip to content

Commit

Permalink
~6차 스프린트 작업사항 (23.08.17) (#57)
Browse files Browse the repository at this point in the history
  • Loading branch information
junhea authored Aug 17, 2023
2 parents 6c1857f + 0834a3f commit 10ed745
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: 'Build and deploy'

on:
push:
branches: ['main']
workflow_dispatch:

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Deploy with AWS SSM Send-Command
uses: peterkimzz/[email protected]
id: ssm
with:
aws-region: ${{ secrets.AWS_REGION }}
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
instance-ids: ${{ secrets.INSTANCE_ID }}
working-directory: /
command: |
#!/bin/bash
export HOME=${{ secrets.ENV_HOME }}
cd ~/watchboard-front
git checkout -- .
git pull
yarn install
yarn build
pm2 startOrRestart ecosystem.config.js
10 changes: 10 additions & 0 deletions ecosystem.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
module.exports = {
apps: [
{
name: 'watchboard-front',
script: 'node_modules/next/dist/bin/next',
args: 'start',
exec_mode: 'cluster',
},
],
};

0 comments on commit 10ed745

Please sign in to comment.