docs: README에 Funch 소개 작성 #7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deployment | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
funch-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: funch server deploy | |
env: | |
SSH_PRIVATE_KEY: ${{ secrets.FUNCH_SSH_KEY }} | |
SERVER_HOST: ${{ secrets.FUNCH_HOST }} | |
SERVER_USER: ${{ secrets.FUNCH_USER }} | |
run: | | |
echo "${FUNCH_SSH_KEY}" > deploy_key | |
chmod 600 deploy_key | |
ssh -i deploy_key ${{ secrets.FUNCH_USER }}@${{ secrets.FUNCH_HOST}} | |
cd /root/web25-funch | |
git switch main | |
git pull origin main | |
pm2 reload ecosystem.config.js | |
media-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: media server deploy | |
env: | |
SSH_PRIVATE_KEY: ${{ secrets.MEDIA_SSH_KEY }} | |
SERVER_HOST: ${{ secrets.MEDIA_HOST }} | |
SERVER_USER: ${{ secrets.MEDIA_USER }} | |
run: | | |
echo "${MEDIA_SSH_KEY}" > deploy_key | |
chmod 600 deploy_key | |
ssh -i deploy_key ${{ secrets.MEDIA_USER }}@${{ secrets.MEDIA_HOST}} | |
git switch main | |
cd /service/web25-funch | |
git pull origin main | |
cd mediaServer | |
pm2 reload ecosystem.config.js |