Skip to content

Commit 57fa2f3

Browse files
committed
chore: add deployment monitoring via github actions
1 parent b23fb5b commit 57fa2f3

File tree

1 file changed

+70
-0
lines changed

1 file changed

+70
-0
lines changed
+70
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
name: Deployment Tests
2+
3+
on:
4+
push:
5+
branches:
6+
- chore/CLI-441_deployment_test
7+
schedule:
8+
- cron: '0 23 * * *'
9+
workflow_dispatch:
10+
11+
jobs:
12+
monitor_cdn:
13+
name: CDN deployments
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: echo UTC > /etc/timezone && apt update && apt install -y sudo curl
25+
- name: Install Snyk
26+
run: |
27+
date -u
28+
rm -f ./snyk
29+
curl --retry 2 -L -v --compressed https://<< matrix.base_url >>/cli/<< matrix.channel >>/snyk-linux -o ./snyk-linux
30+
curl --retry 2 -L -v --compressed https://<< matrix.base_url >>/cli/<< matrix.channel >>/snyk-linux.sha256 -o ./snyk-linux.sha256
31+
echo --- Content shasum file ---
32+
cat snyk-linux.sha256
33+
echo --- Shasum binary ---
34+
sha256sum snyk-linux
35+
chmod +x ./snyk-linux
36+
echo --- CLI version ---
37+
./snyk-linux --version
38+
echo --- Shasum comparison ---
39+
sha256sum -c snyk-linux.sha256
40+
- name: Run snyk --version
41+
run: ./snyk-linux --version
42+
43+
44+
monitor_homebrew:
45+
name: Homebrew deployment
46+
runs-on: ${{ matrix.os }}-latest
47+
strategy:
48+
fail-fast: false
49+
matrix:
50+
os: [ macos ]
51+
steps:
52+
- name: Install Snyk CLI with homebrew on macOS
53+
run: |
54+
brew tap snyk/tap
55+
brew install snyk
56+
- name: Run snyk --version
57+
run: snyk --version
58+
59+
monitor_scoop:
60+
name: Scoop deployment
61+
runs-on: windows-latest
62+
steps:
63+
- name: Install scoop on Windows
64+
run: |
65+
iwr -useb get.scoop.sh -outfile 'install-scoop.ps1'
66+
.\install-scoop.ps1 -RunAsAdmin
67+
scoop bucket add snyk https://github.com/snyk/scoop-snyk
68+
scoop install snyk
69+
- name: Run snyk --version
70+
run: snyk --version

0 commit comments

Comments
 (0)