Skip to content

Workflow file for this run

name: Deploy
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '14' # Specify the Node.js version you need
- name: Install dependencies
run: npm install
- name: Run tests
run: npm test
- name: Build project
run: npm run build
- name: Deploy to OnDemand
env:
ONDEMAND_API_KEY: ${{ secrets.ONDEMAND_API_KEY }}
run: |
curl -X POST https://api.ondemand.com/deploy \
-H "Authorization: Bearer $ONDEMAND_API_KEY" \
-F "repository=$(basename $GITHUB_REPOSITORY)" \
-F "branch=main" \