Skip to content

🚀 Deploy API to OVH VPS #106

🚀 Deploy API to OVH VPS

🚀 Deploy API to OVH VPS #106

Workflow file for this run

name: 🚀 Deploy api to o2switch
on:
push:
branches: [ 'main' ]
pull_request:
branches: [ 'main' ]
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: 🚚 Get latest code
uses: actions/checkout@v3
- name: 🚀 Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '16.x'
- name: 🔍 Install dependencies
run: cd api && npm install
- name: 🧱 Build application
run: cd api && npm run build
- name: 🛁 Clean install a project
run: cd api/build && npm ci --production
- name: 📂 Sync files
uses: SamKirkland/FTP-Deploy-Action@v4.3.4
with:
server: ${{ secrets.FTP_SERVER }}
username: ${{ secrets.FTP_USERNAME }}
password: ${{ secrets.FTP_PASSWORD }}
port: 21
protocol: ftp
local-dir: ./api/build/
server-dir: aparteasy.api.dibodev.com/