-
Notifications
You must be signed in to change notification settings - Fork 53
74 lines (65 loc) · 3.37 KB
/
ci.yml
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
71
72
73
74
name: CI
on:
pull_request:
branches:
- "*"
push:
branches:
- master
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- name: Install link checker
run: |
curl -fsSL -o liche https://github.com/appscodelabs/liche/releases/download/v0.1.0/liche-linux-amd64
chmod +x liche
sudo mv liche /usr/local/bin/liche
- name: Install codespan schema checker
run: |
curl -fsSL -o codespan-schema-checker https://github.com/kmodules/codespan-schema-checker/releases/latest/download/codespan-schema-checker-linux-amd64
chmod +x codespan-schema-checker
sudo mv codespan-schema-checker /usr/local/bin/codespan-schema-checker
- name: Create Kubernetes cluster
id: kind
uses: engineerd/[email protected]
with:
version: v0.24.0
- name: Prepare cluster for testing
id: local-path
run: |
echo "waiting for nodes to be ready ..."
kubectl wait --for=condition=Ready nodes --all --timeout=5m
kubectl get nodes
echo
echo "install helm 3"
curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash
echo "install kubedb-crds chart"
helm repo add appscode https://charts.appscode.com/stable/
helm repo update
# helm install kubedb-crds appscode/kubedb-crds
# helm install kmodules-crds appscode/kmodules-crds
kubectl create -f https://github.com/cert-manager/cert-manager/releases/download/v1.11.0/cert-manager.crds.yaml
kubectl create -f https://github.com/prometheus-operator/prometheus-operator/releases/download/v0.75.0/stripped-down-crds.yaml
kubectl create -f https://github.com/kmodules/custom-resources/raw/release-1.25/crds/appcatalog.appscode.com_appbindings.yaml
kubectl create -f https://github.com/kmodules/custom-resources/raw/release-1.25/crds/metrics.appscode.com_metricsconfigurations.yaml
kubectl create -f https://github.com/stashed/installer/raw/master/crds/stash-crds.yaml
kubectl create -f https://github.com/kubevault/installer/raw/master/crds/kubevault-crds.yaml
kubectl create -f https://github.com/kubedb/installer/raw/master/crds/kubedb-crds.yaml
kubectl create -f https://github.com/kubernetes-csi/external-snapshotter/raw/master/client/config/crd/snapshot.storage.k8s.io_volumesnapshotclasses.yaml
kubectl create -f https://github.com/kubestash/installer/raw/master/crds/kubestash-crds.yaml
- name: Check codespan schema
run: |
git clone https://github.com/kmodules/resource-metadata.git
mv resource-metadata/hub /tmp
rm -rf resource-metadata
codespan-schema-checker --content=./docs
- name: Check links
run: |
liche -r docs -d $(pwd) -c 10 -p -h -l -x '^(.*github.com.*|.*api.slack.com.*|.*twitter.com.*|.*linode.com.*|.*helm.sh.*|.*k8s.io.*|.*percona.com.*|.*kubernetes.io.*|.*search-guard.com.*|.*hub.docker.com.*|.*appscode.com.*|.*mongodb.com.*|.*community.arm.com.*|.*cluster.com.*|.*proxysql.com.*|.*kafka.com.*|.*stackoverflow.com.*|.*redis.io.*|.*elastic.co.*|.*mysql.*)$'