forked from hashicorp/terraform-provider-kubernetes
-
Notifications
You must be signed in to change notification settings - Fork 1
57 lines (54 loc) · 1.43 KB
/
check_examples.yaml
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
name: Check examples
on:
push:
branches:
- main
paths:
- "_examples/kubernetes_manifest/**"
- "**.go"
pull_request:
branches:
- main
paths:
- "_examples/kubernetes_manifest/**"
- "**.go"
workflow_dispatch:
env:
KUBECONFIG: ${{ github.workspace }}/.kube/config
jobs:
check:
runs-on: ubuntu-latest
strategy:
matrix:
terraform_version:
- "1.2.9"
- "1.3.9"
- "1.4.0"
- "1.6.0"
- "1.7.0"
- "1.8.0"
env:
TF_X_KUBERNETES_MANIFEST_RESOURCE: 1
TERM: linux
steps:
- uses: hashicorp/setup-terraform@a1502cd9e758c50496cc9ac5308c4843bcd56d36 # v3.0.0
with:
terraform_version: ${{ matrix.terraform_version }}
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
- name: Set up Go
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
with:
go-version-file: 'go.mod'
- name: Go mod verify
run: go mod verify
- name: Go build
run: go build
- name: Setup kind
uses: helm/kind-action@99576bfa6ddf9a8e612d83b513da5a75875caced # v1.9.0
with:
wait: 2m
version: "v0.17.0" # Kubernetes version: 1.25.X
- name: Check examples run
env:
KUBE_CONFIG_PATH: ${{ env.KUBECONFIG }}
run: ./manifest/scripts/check_examples.sh