Skip to content

feat: ✨ projectPreview 에 difficulty 추가 #150

feat: ✨ projectPreview 에 difficulty 추가

feat: ✨ projectPreview 에 difficulty 추가 #150

Workflow file for this run

name: CI/CD
on:
push:
branches:
- dev
release:
types:
- created
jobs:
CD-dev:
name: develop
if: github.ref == 'refs/heads/dev'
runs-on: ubuntu-latest
# needs: CI
steps:
- name: Deploy to Dev EC2
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.EC2_DEV_HOST }}
username: ${{ secrets.EC2_USER }}
key: ${{ secrets.EC2_SSH_KEY }}
script: |
echo "move to repository"
cd $HOME/42Stat-Backend
echo "pull"
git pull origin dev
echo "env update"
git submodule update --remote
echo "run docker"
docker-compose -f docker-compose.dev.yml down -v
docker-compose -f docker-compose.dev.yml up -d
CD-prod:
name: production
if: startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
# needs: CI
steps:
- name: Deploy to Prod EC2
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.EC2_PROD_HOST }}
username: ${{ secrets.EC2_USER }}
key: ${{ secrets.EC2_SSH_KEY }}
script: |
cd $HOME/42Stat-Backend
git pull origin main
git submodule update --remote
docker-compose -f docker-compose.prod.yml down -v
docker-compose -f docker-compose.prod.yml up -d