-
Notifications
You must be signed in to change notification settings - Fork 800
64 lines (55 loc) · 2.01 KB
/
update-jetpack-staging-sites.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
59
60
61
62
63
64
name: Update Jetpack Staging Test Sites
# Ran as part of the `UpdateJetpackStaging` TeamCity build.
# After updating the sites, runs k6 tests against the same sites.
on:
workflow_dispatch:
jobs:
run_shell_script:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Env config
env:
SSH_KEY: ${{ secrets.UPDATEJETPACKSTAGING_SSH_KEY }}
SSH_KNOWN_HOSTS: ${{ secrets.UPDATEJETPACKSTAGING_SSH_KNOWN_HOSTS }}
run: |
mkdir -p ~/.ssh/
echo "$SSH_KNOWN_HOSTS" > ~/.ssh/known_hosts
echo "$SSH_KEY" > ~/.ssh/id_rsa
chmod 0600 ~/.ssh/id_rsa
- name: Execute shell script
shell: bash
run: .github/files/jetpack-staging-sites/update-jetpack-staging-sites.sh
run_k6_tests:
needs: run_shell_script
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Run k6 frontend tests
uses: grafana/[email protected]
with:
filename: .github/files/jetpack-staging-sites/k6-frontend.js
env:
JETPACKSTAGING_K6_USERNAME: ${{ secrets.JETPACKSTAGING_K6_USERNAME }}
JETPACKSTAGING_K6_PASSWORD: ${{ secrets.JETPACKSTAGING_K6_PASSWORD }}
- name: Run k6 backend tests
uses: grafana/[email protected]
with:
filename: .github/files/jetpack-staging-sites/k6-backend.js
env:
JETPACKSTAGING_K6_USERNAME: ${{ secrets.JETPACKSTAGING_K6_USERNAME }}
JETPACKSTAGING_K6_PASSWORD: ${{ secrets.JETPACKSTAGING_K6_PASSWORD }}
trigger_e2e_tests:
needs: run_shell_script
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Execute shell script
shell: bash
run: .github/files/jetpack-staging-sites/run-atomic-deploy-e2e-tests.sh
env:
SIGNATURE_KEY: ${{ secrets.ATOMIC_DEPLOY_E2E_TESTS_KEY }}
TRIGGER_URL: ${{ secrets.ATOMIC_DEPLOY_E2E_TESTS_URL }}