Skip to content

push deploy api and widget #1

push deploy api and widget

push deploy api and widget #1

name: Deploy widget benevolat production
on:
push:
branches:
- main
paths:
- ".github/workflows/deploy-widget-benevolat-production.yml"
- "widget-benevolat/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
deploy:
runs-on: ubuntu-latest
environment: production
steps:
- name: Connect and restart process
uses: appleboy/ssh-action@master
with:
host: mission.api-engagement.beta.gouv.fr
username: "root"
key: ${{ secrets.SCW_SSH_KEY }}
script: |
cd api-engagement/widget-benevolat
git checkout main
git reset --hard
git pull
npm install
npm run build
npm run stop
npm run start