Skip to content

Commit d07e237

Browse files
committed
test test test
1 parent b634fb3 commit d07e237

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

.werft/k3s-installer-tests.yaml

+8-1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ pod:
5151
- name: sh-playground-dns-perm
5252
secret:
5353
secretName: sh-playground-dns-perm
54+
- name: self-hosted-github-oauth
55+
secret:
56+
secretName: self-hosted-github-oauth
5457
containers:
5558
- name: nightly-test
5659
image: eu.gcr.io/gitpod-core-dev/dev/dev-environment:pd-dev-upgrade.0
@@ -61,13 +64,17 @@ pod:
6164
mountPath: /mnt/secrets/sh-playground-sa-perm
6265
- name: sh-playground-dns-perm # this sa is used for the DNS management
6366
mountPath: /mnt/secrets/sh-playground-dns-perm
67+
- name: self-hosted-github-oauth
68+
mountPath: "/mnt/secrets/github-oauth"
6469
env:
6570
- name: GOOGLE_APPLICATION_CREDENTIALS
6671
value: "/mnt/secrets/sh-playground-sa-perm/sh-sa.json"
6772
- name: TF_VAR_sa_creds
6873
value: "/mnt/secrets/sh-playground-sa-perm/sh-sa.json"
6974
- name: TF_VAR_dns_sa_creds
7075
value: "/mnt/secrets/sh-playground-dns-perm/sh-dns-sa.json"
76+
- name: GITHUB_SCM_OAUTH
77+
value: "/mnt/secrets/github-oauth/provider"
7178
- name: NODENAME
7279
valueFrom:
7380
fieldRef:
@@ -117,7 +124,7 @@ pod:
117124
export domain="{{ .Annotations.subdomain }}"
118125
119126
if [[ "$domain" == "<no value>" ]]; then
120-
export TF_VAR_TEST_ID="$(echo $RANDOM | md5sum | head -c 5; echo)-k3s"
127+
export TF_VAR_TEST_ID="p$(echo $RANDOM | md5sum | head -c 5; echo)-k3s"
121128
else
122129
export TF_VAR_TEST_ID="$domain"
123130
fi

install/tests/Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ get-kubeconfig: ${cloud}-kubeconfig
162162
get-github-config:
163163
ifneq ($(GITHUB_SCM_OAUTH),)
164164
export SCM_OAUTH=./manifests/github-oauth.yaml && \
165-
cat $$GITHUB_SCM_OAUTH/provider > $$SCM_OAUTH && \
166-
yq w -i $$SCM_OAUTH 'oauth.callBackUrl' http://${TF_VAR_TEST_ID}.${DOMAIN}/auth/github.com/callback && \
165+
cat $$GITHUB_SCM_OAUTH > $$SCM_OAUTH && \
166+
yq w -i $$SCM_OAUTH 'oauth.callBackUrl' http://sh-preview.gitpod-dev.com/auth/github.com/callback/${TF_VAR_TEST_ID} && \
167167
kubectl --kubeconfig=${KUBECONFIG} create namespace gitpod || echo "Gitpod namespace already exist" && \
168168
kubectl --kubeconfig=${KUBECONFIG} delete secret github-oauth -n gitpod || echo "gitpod-oauth secret needs to be created" && \
169169
kubectl --kubeconfig=${KUBECONFIG} create secret generic "github-oauth" --namespace gitpod --from-literal=provider="$$(cat $$SCM_OAUTH)" && \

0 commit comments

Comments
 (0)