Skip to content

Commit 4fbc67f

Browse files
committed
chore: add deployment monitoring via github actions
1 parent b23fb5b commit 4fbc67f

File tree

1 file changed

+86
-0
lines changed

1 file changed

+86
-0
lines changed
+86
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
name: Deployment Tests
2+
3+
on:
4+
push:
5+
paths:
6+
- '.github/workflows/deployment-monitor.yml'
7+
schedule:
8+
- cron: '0 */2 * * *'
9+
workflow_dispatch:
10+
11+
jobs:
12+
monitor_cdn:
13+
name: CDN deployment
14+
runs-on: ${{ matrix.os }}-latest
15+
strategy:
16+
fail-fast: false
17+
matrix:
18+
os: [ubuntu]
19+
base_url: [static.snyk.io, downloads.snyk.io]
20+
channel: [stable, preview]
21+
steps:
22+
- uses: actions/checkout@v2
23+
- name: Install dependencies
24+
run: sudo apt update && sudo apt install -y curl
25+
- name: Install Snyk
26+
run: |
27+
rm -f ./snyk
28+
curl --retry 2 -L -v --compressed https://${{ matrix.base_url }}/cli/${{ matrix.channel }}/snyk-linux -o ./snyk-linux
29+
curl --retry 2 -L -v --compressed https://${{ matrix.base_url }}/cli/${{ matrix.channel }}/snyk-linux.sha256 -o ./snyk-linux.sha256
30+
echo --- Content shasum file ---
31+
cat snyk-linux.sha256
32+
echo --- Shasum binary ---
33+
sha256sum snyk-linux
34+
chmod +x ./snyk-linux
35+
echo --- CLI version ---
36+
./snyk-linux --version
37+
echo --- Shasum comparison ---
38+
sha256sum -c snyk-linux.sha256
39+
- name: Run snyk --version
40+
run: ./snyk-linux --version
41+
42+
43+
monitor_homebrew:
44+
name: Homebrew deployment (macos)
45+
runs-on: macos-latest
46+
steps:
47+
- name: Install Snyk
48+
run: |
49+
brew tap snyk/tap
50+
brew install snyk
51+
- name: Run snyk --version
52+
run: snyk --version
53+
54+
monitor_scoop:
55+
name: Scoop deployment (windows)
56+
runs-on: windows-latest
57+
steps:
58+
- name: Install Scoop and Snyk
59+
run: |
60+
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
61+
Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression
62+
scoop bucket add snyk https://github.com/snyk/scoop-snyk
63+
scoop install snyk
64+
snyk --version
65+
66+
monitor_npm:
67+
name: npm deployment (ubuntu)
68+
runs-on: ubuntu-latest
69+
steps:
70+
- uses: actions/setup-node@v4
71+
with:
72+
node-version: latest
73+
- name: Install Snyk
74+
run: |
75+
npm install -g snyk
76+
snyk --version
77+
78+
monitor_snyk_images:
79+
name: snyk-images deployment (snyk/snyk:linux)
80+
runs-on: ubuntu-latest
81+
container:
82+
image: snyk/snyk:linux
83+
steps:
84+
- name: Install Snyk
85+
run: |
86+
snyk --version

0 commit comments

Comments
 (0)