This repository was archived by the owner on Aug 6, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: pbochynski <[email protected]>
- Loading branch information
1 parent
d455737
commit 2630b89
Showing
12 changed files
with
185 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Tests on kind | ||
|
||
on: | ||
push: | ||
pull_request: | ||
types: [opened, synchronize, reopened] | ||
schedule: | ||
- cron: '0 * * * *' # every hour | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Prepare docker registry, kind & helm 3 | ||
run: | | ||
echo "Installing kind" | ||
GO111MODULE="on" go get sigs.k8s.io/[email protected] | ||
echo "Starting docker registry & kind cluster" | ||
./create-cluster-kind.sh | ||
echo "Installing helm" | ||
curl -s https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash | ||
- name: Install Istio | ||
run: | | ||
./install-istio.sh -f config-istio-nodeport.yaml | ||
# - name: Setup tmate session | ||
# uses: mxschmitt/action-tmate@v3 | ||
- name: Install Kyma | ||
env: | ||
SKIP_MODULES: apiserver-proxy,helm-broker,console,cluster-users,apiserver-proxy,logging,tracing | ||
run: | | ||
./download-kyma-charts.sh | ||
./install-kyma.sh | ||
sudo cp kyma.crt /usr/local/share/ca-certificates | ||
sudo update-ca-certificates | ||
- name: Install Commerce Mock | ||
run: | | ||
./commerce-mock.sh | ||
- name: Run End To End Test | ||
run: | | ||
./app-connector-example.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ dist | |
registry | ||
coredns-patch.yaml | ||
kyma.crt | ||
istioctl | ||
istio-* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
apiVersion: install.istio.io/v1alpha1 | ||
kind: IstioOperator | ||
spec: | ||
addonComponents: | ||
grafana: | ||
enabled: false | ||
istiocoredns: | ||
enabled: false | ||
kiali: | ||
enabled: false | ||
prometheus: | ||
enabled: false | ||
tracing: | ||
enabled: false | ||
components: | ||
citadel: | ||
enabled: false | ||
cni: | ||
enabled: false | ||
egressGateways: | ||
- enabled: false | ||
name: istio-egressgateway | ||
galley: | ||
enabled: false | ||
ingressGateways: | ||
- enabled: true | ||
k8s: | ||
resources: | ||
requests: | ||
cpu: 10m | ||
memory: 40Mi | ||
service: | ||
type: NodePort | ||
overlays: | ||
- apiVersion: v1 | ||
kind: Service | ||
name: istio-ingressgateway | ||
patches: | ||
- path: spec.ports | ||
value: | ||
- name: status-port | ||
port: 15021 | ||
targetPort: 15021 | ||
nodePort: 30002 | ||
- name: http2 | ||
port: 80 | ||
targetPort: 80 | ||
nodePort: 30000 | ||
- name: https | ||
port: 443 | ||
targetPort: 443 | ||
nodePort: 30001 | ||
name: istio-ingressgateway |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
apiVersion: install.istio.io/v1alpha1 | ||
kind: IstioOperator | ||
spec: | ||
addonComponents: | ||
grafana: | ||
enabled: false | ||
istiocoredns: | ||
enabled: false | ||
kiali: | ||
enabled: false | ||
prometheus: | ||
enabled: false | ||
tracing: | ||
enabled: false | ||
components: | ||
citadel: | ||
enabled: false | ||
cni: | ||
enabled: false | ||
egressGateways: | ||
- enabled: false | ||
name: istio-egressgateway | ||
galley: | ||
enabled: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
#!/bin/sh | ||
set -o errexit | ||
|
||
|
||
|
||
# create a cluster with the local registry enabled in containerd | ||
cat <<EOF | kind create cluster --name kyma --config=- | ||
kind: Cluster | ||
apiVersion: kind.x-k8s.io/v1alpha4 | ||
containerdConfigPatches: | ||
- |- | ||
[plugins."io.containerd.grpc.v1.cri".registry.mirrors."registry.localhost:5000"] | ||
endpoint = ["http://registry.localhost:5000"] | ||
nodes: | ||
- role: control-plane | ||
kubeadmConfigPatches: | ||
- | | ||
kind: InitConfiguration | ||
nodeRegistration: | ||
kubeletExtraArgs: | ||
node-labels: "ingress-ready=true" | ||
image: kindest/node:v1.18.8@sha256:f4bcc97a0ad6e7abaf3f643d890add7efe6ee4ab90baeb374b4f41a4c95567eb | ||
extraPortMappings: | ||
- containerPort: 30000 | ||
hostPort: 80 | ||
protocol: tcp | ||
listenAddress: "127.0.0.1" | ||
- containerPort: 30001 | ||
hostPort: 443 | ||
protocol: tcp | ||
listenAddress: "127.0.0.1" | ||
- containerPort: 30002 | ||
hostPort: 15021 | ||
protocol: tcp | ||
listenAddress: "127.0.0.1" | ||
EOF | ||
|
||
# create registry container unless it already exists | ||
docker run -d \ | ||
-p 5000:5000 \ | ||
--restart=always \ | ||
--network=kind \ | ||
--name registry.localhost \ | ||
-v $PWD/registry:/var/lib/registry \ | ||
registry:2 | ||
|
||
# tell https://tilt.dev to use the registry | ||
# https://docs.tilt.dev/choosing_clusters.html#discovering-the-registry | ||
for node in $(kind get nodes --name kyma); do | ||
kubectl annotate node "${node}" "kind.x-k8s.io/registry=registry.localhost:${reg_port}"; | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/sh | ||
set -o errexit | ||
|
||
kind delete cluster --name kyma | ||
docker rm -f registry.localhost |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
./create-cluster-kind.sh | ||
./install-istio.sh | ||
./install-kyma.sh |