Skip to content

Commit d471e0e

Browse files
committed
test test test
1 parent fe26d26 commit d471e0e

File tree

2 files changed

+20
-3
lines changed

2 files changed

+20
-3
lines changed

.werft/k3s-installer-tests.yaml

+18-1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,9 @@ pod:
5555
- name: sh-playground-dns-perm
5656
secret:
5757
secretName: sh-playground-dns-perm
58+
- name: self-hosted-github-oauth
59+
secret:
60+
secretName: self-hosted-github-oauth
5861
containers:
5962
- name: nightly-test
6063
image: eu.gcr.io/gitpod-core-dev/dev/dev-environment:aa-unset-goflags.0
@@ -65,17 +68,31 @@ pod:
6568
mountPath: /mnt/secrets/sh-playground-sa-perm
6669
- name: sh-playground-dns-perm # this sa is used for the DNS management
6770
mountPath: /mnt/secrets/sh-playground-dns-perm
71+
- name: self-hosted-github-oauth
72+
mountPath: "/mnt/secrets/github-oauth"
6873
env:
6974
- name: GOOGLE_APPLICATION_CREDENTIALS
7075
value: "/mnt/secrets/sh-playground-sa-perm/sh-sa.json"
7176
- name: TF_VAR_sa_creds
7277
value: "/mnt/secrets/sh-playground-sa-perm/sh-sa.json"
7378
- name: TF_VAR_dns_sa_creds
7479
value: "/mnt/secrets/sh-playground-dns-perm/sh-dns-sa.json"
80+
- name: GITHUB_SCM_OAUTH
81+
value: "/mnt/secrets/github-oauth/provider"
7582
- name: NODENAME
7683
valueFrom:
7784
fieldRef:
7885
fieldPath: spec.nodeName
86+
- name: ROBOQUAT_TOKEN
87+
valueFrom:
88+
secretKeyRef:
89+
name: github-roboquat-automatic-changelog
90+
key: token
91+
- name: USERNAME
92+
valueFrom:
93+
secretKeyRef:
94+
name: integration-test-user
95+
key: username
7996
- name: USER_TOKEN # this is for the integration tests
8097
valueFrom:
8198
secretKeyRef:
@@ -126,7 +143,7 @@ pod:
126143
export domain="{{ .Annotations.subdomain }}"
127144
128145
if [[ "$domain" == "<no value>" ]]; then
129-
export TF_VAR_TEST_ID="$(echo $RANDOM | md5sum | head -c 5; echo)-k3s"
146+
export TF_VAR_TEST_ID="p$(echo $RANDOM | md5sum | head -c 5; echo)-k3s"
130147
else
131148
export TF_VAR_TEST_ID="$domain"
132149
fi

install/tests/Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -165,8 +165,8 @@ get-kubeconfig: ${cloud}-kubeconfig
165165
get-github-config:
166166
ifneq ($(GITHUB_SCM_OAUTH),)
167167
export SCM_OAUTH=./manifests/github-oauth.yaml && \
168-
cat $$GITHUB_SCM_OAUTH/provider > $$SCM_OAUTH && \
169-
yq w -i $$SCM_OAUTH 'oauth.callBackUrl' http://${TF_VAR_TEST_ID}.${DOMAIN}/auth/github.com/callback && \
168+
cat $$GITHUB_SCM_OAUTH > $$SCM_OAUTH && \
169+
yq w -i $$SCM_OAUTH 'oauth.callBackUrl' https://scm.${DOMAIN}/auth/github.com/callback?state=${TF_VAR_TEST_ID} && \
170170
kubectl --kubeconfig=${KUBECONFIG} create namespace gitpod || echo "Gitpod namespace already exist" && \
171171
kubectl --kubeconfig=${KUBECONFIG} delete secret github-oauth -n gitpod || echo "gitpod-oauth secret needs to be created" && \
172172
kubectl --kubeconfig=${KUBECONFIG} create secret generic "github-oauth" --namespace gitpod --from-literal=provider="$$(cat $$SCM_OAUTH)" && \

0 commit comments

Comments
 (0)