cloudflare/pint

Public

mirrored from https://github.com/cloudflare/pintAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
main

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

.github/workflows/examples.yml

46lines · modecode

1name: Validate examples
2
3on:
4 push:
5 branches:
6 - main
7 pull_request:
8 branches:
9 - main
10
11permissions: read-all
12
13jobs:
14 examples:
15 runs-on: ubuntu-latest
16 steps:
17 - name: Check out code
18 uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
19 with:
20 show-progress: false
21
22 - name: Set up Go
23 uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
24 with:
25 go-version-file: go.ver
26 cache: false
27
28 - name: Build binary
29 run: make
30
31 - name: Generate dummy TLS certificates
32 run: |
33 sudo mkdir -p /etc/pint/certs
34 sudo chmod 777 /etc/pint/certs
35 openssl req -x509 -newkey rsa:2048 -keyout /dev/null -out /etc/pint/certs/ca.pem -days 1 -nodes -subj "/CN=test-ca"
36 openssl req -x509 -newkey rsa:2048 -keyout /etc/pint/certs/client.key -out /etc/pint/certs/client.pem -days 1 -nodes -subj "/CN=test-client"
37
38 - name: Verify examples
39 env:
40 AUTH_KEY: "12345"
41 PROMETHEUS_AUTH_TOKEN: "abcdef"
42 run: |
43 for CFG in docs/examples/* ; do
44 echo ">>> $CFG"
45 ./pint -c "$CFG" config
46 done
47