-
Notifications
You must be signed in to change notification settings - Fork 6
58 lines (50 loc) · 1.41 KB
/
deploy_website.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
46
47
48
49
50
51
52
53
54
55
56
57
58
name: deploy_language_referemce
on:
push:
branches:
- master
paths:
- '.github/workflows/deploy_website.yml'
- 'teachprogramming/lib/**'
- 'teachprogramming/static/language_reference/**'
jobs:
checkout:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
debug:
runs-on: ubuntu-latest
steps:
- run: ls -la
compile_and_run_languages:
needs: [checkout]
runs-on: ubuntu-latest
steps:
- working-directory: teachprogramming/static/language_reference
run: make build_and_run
build_static:
needs: [checkout]
runs-on: ubuntu-latest
steps:
- working-directory: teachprogramming/lib
run: make build_static
deploy_static:
needs: [compile_and_run_languages, build_static]
runs-on: ubuntu-latest
steps:
- name: scp_api
uses: appleboy/scp-action@master
with:
host: computingteachers.uk
username: computingteachers
key: ${{ secrets.DEPLOY_SSH_KEY }}
source: "teachprogramming/lib/api/v1"
target: "computingteachers.uk/api"
- name: scp_static
uses: appleboy/scp-action@master
with:
host: computingteachers.uk
username: computingteachers
key: ${{ secrets.DEPLOY_SSH_KEY }}
source: "teachprogramming/lib/static"
target: "computingteachers.uk"