UNCLASSIFIED - NO CUI

Skip to content
Snippets Groups Projects
Commit 1432959c authored by Micah Nagel's avatar Micah Nagel
Browse files

SKIP UPGRADE: Fix Keycloak in Master CI

parent f89c6f2a
No related branches found
No related tags found
1 merge request!910SKIP UPGRADE: Fix Keycloak in Master CI
......@@ -2,7 +2,7 @@
set -ex
# if keycloak label or all packages label add deploy k3d without loadbalancer so metallb can be used
if [[ $CI_MERGE_REQUEST_LABELS =~ "keycloak" || $CI_MERGE_REQUEST_LABELS =~ "all-packages" ]]; then
if [[ "${CI_COMMIT_BRANCH}" == "${CI_DEFAULT_BRANCH}" ]] || [[ ! -z "$CI_COMMIT_TAG" ]] || [[ $CI_MERGE_REQUEST_LABELS =~ "keycloak" || $CI_MERGE_REQUEST_LABELS =~ "all-packages" ]]; then
k3d cluster create ${CI_JOB_ID} --config tests/ci/k3d/disable-servicelb-config.yaml --network ${CI_JOB_ID}
else
k3d cluster create ${CI_JOB_ID} --config tests/ci/k3d/config.yaml --network ${CI_JOB_ID}
......
......@@ -2,7 +2,7 @@
set -ex
if [[ $CI_MERGE_REQUEST_LABELS =~ "keycloak" || $CI_MERGE_REQUEST_LABELS =~ "all-packages" ]]; then
if [[ "${CI_COMMIT_BRANCH}" == "${CI_DEFAULT_BRANCH}" ]] || [[ ! -z "$CI_COMMIT_TAG" ]] || [[ $CI_MERGE_REQUEST_LABELS =~ "keycloak" || $CI_MERGE_REQUEST_LABELS =~ "all-packages" ]]; then
kubectl create -f tests/ci/k3d/metallb/metallb.yaml
kubectl create -f tests/ci/k3d/metallb/metallb-config.yaml
else
......
......@@ -5,12 +5,12 @@ set -e
# Populate /etc/hosts
ip=$(kubectl -n istio-system get service public-ingressgateway -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
ip_passthrough=$(kubectl -n istio-system get service passthrough-ingressgateway -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo "Checking "
hosts=`kubectl get virtualservices -A -o jsonpath="{ .items[*].spec.hosts[*] }"`
for host in $hosts; do
if [ $host == "keycloak.bigbang.dev" ]; then
ip_passthrough=$(kubectl -n istio-system get service passthrough-ingressgateway -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo "$ip_passthrough $host" >> /etc/hosts
else
echo "$ip $host" >> /etc/hosts
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment