Skip to content

Commit

Permalink
ci: expose longhorn frontend for debugging
Browse files Browse the repository at this point in the history
Signed-off-by: Yang Chiu <yang.chiu@suse.com>
  • Loading branch information
yangchiu committed Sep 12, 2024
1 parent 6ce7118 commit c084457
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
7 changes: 7 additions & 0 deletions test_framework/scripts/longhorn-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -x

source test_framework/scripts/kubeconfig.sh
source pipelines/utilities/longhorn_manifest.sh
source pipelines/utilities/longhorn_ui.sh

# create and clean tmpdir
TMPDIR="/tmp/longhorn"
Expand Down Expand Up @@ -543,6 +544,8 @@ main(){
get_rancher_api_key
install_longhorn_by_rancher
fi
setup_longhorn_ui_nodeport
export_longhorn_ui_url
run_longhorn_tests
elif [[ "${LONGHORN_UPGRADE_TEST}" == true ]]; then
generate_longhorn_yaml_manifest "${TF_VAR_tf_workspace}"
Expand All @@ -556,6 +559,8 @@ main(){
UPGRADE_LH_INSTANCE_MANAGER_IMAGE="${CUSTOM_LONGHORN_INSTANCE_MANAGER_IMAGE}"
UPGRADE_LH_SHARE_MANAGER_IMAGE="${CUSTOM_LONGHORN_SHARE_MANAGER_IMAGE}"
UPGRADE_LH_BACKING_IMAGE_MANAGER_IMAGE="${CUSTOM_LONGHORN_BACKING_IMAGE_MANAGER_IMAGE}"
setup_longhorn_ui_nodeport
export_longhorn_ui_url
run_longhorn_upgrade_test
run_longhorn_tests
else
Expand All @@ -566,6 +571,8 @@ main(){
generate_longhorn_yaml_manifest "${TF_VAR_tf_workspace}"
install_longhorn_by_manifest "${TF_VAR_tf_workspace}/longhorn.yaml"
fi
setup_longhorn_ui_nodeport
export_longhorn_ui_url
run_longhorn_tests
fi
}
Expand Down
4 changes: 4 additions & 0 deletions test_framework/scripts/terraform-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ terraform_setup(){
terraform -chdir=${TF_VAR_tf_workspace}/terraform/${LONGHORN_TEST_CLOUDPROVIDER}/${DISTRO} init
terraform -chdir=${TF_VAR_tf_workspace}/terraform/${LONGHORN_TEST_CLOUDPROVIDER}/${DISTRO} apply -auto-approve -no-color

if [[ ${LONGHORN_TEST_CLOUDPROVIDER} == "aws" ]]; then
terraform -chdir=${TF_VAR_tf_workspace}/terraform/${LONGHORN_TEST_CLOUDPROVIDER}/${DISTRO} output -raw controlplane_public_ip > /tmp/controlplane_public_ip
fi

if [[ ${TF_VAR_k8s_distro_name} == "rke" ]]; then
terraform -chdir=${TF_VAR_tf_workspace}/terraform/${LONGHORN_TEST_CLOUDPROVIDER}/${DISTRO} apply -auto-approve -no-color -refresh-only
terraform -chdir=${TF_VAR_tf_workspace}/terraform/${LONGHORN_TEST_CLOUDPROVIDER}/${DISTRO} output -raw rke_config > ${TF_VAR_tf_workspace}/rke.yml
Expand Down

0 comments on commit c084457

Please sign in to comment.