-
Notifications
You must be signed in to change notification settings - Fork 44
70 lines (59 loc) · 1.92 KB
/
ci-master-scheduled.yml
File metadata and controls
70 lines (59 loc) · 1.92 KB
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
65
66
67
68
69
70
name: CI - Master - Scheduled
on:
schedule:
- cron: "0 1 * * *" # 1 AM everyday https://crontab.guru/#0_1_*_*_*
workflow_dispatch:
jobs:
scheduled-test:
strategy:
max-parallel: 1
fail-fast: false
matrix:
python_version:
# https://python-release-cycle.glitch.me/
- "3.7"
- "3.8"
- "3.9"
- "3.10"
- "3.11"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python_version }}
- name: Lint
uses: astral-sh/ruff-action@v3
- name: Check format
run: ruff format --check
- name: Travis Test - Start agent
id: start_agent
env:
PYTHON_SDC_TEST_ACCESS_KEY: ${{ secrets.STAGING_AGENT_KEY }}
run: |
sudo apt-get update
sudo apt-get install linux-headers-$(uname -r) dkms gcc-multilib g++-multilib
./test/start_agent.sh
- name: Travis Test - Install dependencies
run: |
uv build
python -m pip install $(find dist -iname "*.whl" | head -1)
- name: Travis Test - Secure APIs
env:
PYTHON_SDC_TEST_API_TOKEN: ${{ secrets.STAGING_SECURE_API_TOKEN }}
run: ./test/test_secure_apis.sh
- name: Test in staging
env:
SDC_MONITOR_TOKEN: ${{ secrets.STAGING_MONITOR_API_TOKEN }}
SDC_SECURE_TOKEN: ${{ secrets.STAGING_SECURE_API_TOKEN }}
SDC_MONITOR_URL: "https://app-staging.sysdigcloud.com"
SDC_SECURE_URL: "https://secure-staging.sysdig.com"
run: uv run mamba -f documentation
- name: Travis Test - Stop agent
run: ./test/stop_agent.sh
if: steps.start_agent.outcome == 'success'