@@ -3,6 +3,7 @@ name: CI - Master - Scheduled
3
3
on :
4
4
schedule :
5
5
- cron : " 0 1 * * *" # 1 AM everyday https://crontab.guru/#0_1_*_*_*
6
+ workflow_dispatch :
6
7
7
8
jobs :
8
9
scheduled-test :
@@ -18,62 +19,62 @@ jobs:
18
19
- " 3.9"
19
20
runs-on : ubuntu-latest
20
21
steps :
21
- - uses : actions/checkout@v2
22
+ - uses : actions/checkout@v2
22
23
23
- - uses : actions/setup-python@v2
24
- with :
25
- python-version : ${{ matrix.python_version }}
24
+ - uses : actions/setup-python@v2
25
+ with :
26
+ python-version : ${{ matrix.python_version }}
26
27
27
- - name : Install Poetry
28
- run : python -m pip install poetry poetry-dynamic-versioning
28
+ - name : Install Poetry
29
+ run : python -m pip install poetry poetry-dynamic-versioning
29
30
30
- - uses : actions/cache@v2
31
- name : Cache Poetry dependencies
32
- with :
33
- path : |
34
- ~/.cache
35
- ~/.local/share/virtualenvs/
36
- key : ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }}
37
- restore-keys : |
38
- ${{ runner.os }}-poetry-
31
+ - uses : actions/cache@v2
32
+ name : Cache Poetry dependencies
33
+ with :
34
+ path : |
35
+ ~/.cache
36
+ ~/.local/share/virtualenvs/
37
+ key : ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }}
38
+ restore-keys : |
39
+ ${{ runner.os }}-poetry-
39
40
40
- - name : Get dependencies
41
- run : poetry install
41
+ - name : Get dependencies
42
+ run : poetry install
42
43
43
- - name : Lint
44
- continue-on-error : true
45
- run : |
46
- # stop the build if there are Python syntax errors or undefined names
47
- poetry run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
48
- # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
49
- poetry run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
44
+ - name : Lint
45
+ continue-on-error : true
46
+ run : |
47
+ # stop the build if there are Python syntax errors or undefined names
48
+ poetry run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
49
+ # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
50
+ poetry run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
50
51
51
- - name : Travis Test - Start agent
52
- id : start_agent
53
- env :
54
- PYTHON_SDC_TEST_ACCESS_KEY : ${{ secrets.STAGING_AGENT_KEY }}
55
- run : |
56
- sudo apt-get install linux-headers-$(uname -r) dkms gcc-multilib g++-multilib
57
- ./test/start_agent.sh
52
+ - name : Travis Test - Start agent
53
+ id : start_agent
54
+ env :
55
+ PYTHON_SDC_TEST_ACCESS_KEY : ${{ secrets.STAGING_AGENT_KEY }}
56
+ run : |
57
+ sudo apt-get install linux-headers-$(uname -r) dkms gcc-multilib g++-multilib
58
+ ./test/start_agent.sh
58
59
59
- - name : Travis Test - Install dependencies
60
- run : |
61
- poetry build
62
- python -m pip install $(find dist -iname "*.whl" | head -1)
60
+ - name : Travis Test - Install dependencies
61
+ run : |
62
+ poetry build
63
+ python -m pip install $(find dist -iname "*.whl" | head -1)
63
64
64
- - name : Travis Test - Secure APIs
65
- env :
66
- PYTHON_SDC_TEST_API_TOKEN : ${{ secrets.STAGING_SECURE_API_TOKEN }}
67
- run : ./test/test_secure_apis.sh
65
+ - name : Travis Test - Secure APIs
66
+ env :
67
+ PYTHON_SDC_TEST_API_TOKEN : ${{ secrets.STAGING_SECURE_API_TOKEN }}
68
+ run : ./test/test_secure_apis.sh
68
69
69
- - name : Test in staging
70
- env :
71
- SDC_MONITOR_TOKEN : ${{ secrets.STAGING_MONITOR_API_TOKEN }}
72
- SDC_SECURE_TOKEN : ${{ secrets.STAGING_SECURE_API_TOKEN }}
73
- SDC_MONITOR_URL : " https://app-staging.sysdigcloud.com"
74
- SDC_SECURE_URL : " https://secure-staging.sysdig.com"
75
- run : poetry run mamba -f documentation
70
+ - name : Test in staging
71
+ env :
72
+ SDC_MONITOR_TOKEN : ${{ secrets.STAGING_MONITOR_API_TOKEN }}
73
+ SDC_SECURE_TOKEN : ${{ secrets.STAGING_SECURE_API_TOKEN }}
74
+ SDC_MONITOR_URL : " https://app-staging.sysdigcloud.com"
75
+ SDC_SECURE_URL : " https://secure-staging.sysdig.com"
76
+ run : poetry run mamba -f documentation
76
77
77
- - name : Travis Test - Stop agent
78
- run : ./test/stop_agent.sh
79
- if : steps.start_agent.outcome == 'success'
78
+ - name : Travis Test - Stop agent
79
+ run : ./test/stop_agent.sh
80
+ if : steps.start_agent.outcome == 'success'
0 commit comments