-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (37 loc) · 1.07 KB
/
development.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Development
on:
push:
branches: [ development ]
pull_request:
branches: [ development ]
jobs:
test:
name: Test application
runs-on: ubuntu-latest
steps:
- name: "☁️ checkout repository"
uses: actions/checkout@v3
- name: "🔧 setup node"
uses: actions/setup-node@v3
with:
node-version: '16.x'
cache: 'npm'
- name: "📦 install dependencies"
run: npm ci
- name: "📦 build code"
run: npm run build --if-present
- name: "🔍 run tests"
run: npm test
deploy:
name: Deploy to staging
needs: test
if: github.ref == 'refs/heads/development'
runs-on: ubuntu-latest
steps:
- name: "🚀 call webhook on staging server"
id: call_webhook
uses: distributhor/workflow-webhook@v3
env:
webhook_url: https://staging.hook-runner.landexplorer.coop/run.php?target=land-explorer-back-end
- name: "👂 echo response from webhook"
run: echo "${{steps.call_webhook.outputs.response-body}}"