Skip to content

[PDP-3405] add support for service type #25

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions dev/platform-provisioner-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,25 @@
# platform-provisioner-install.sh: this will deploy all supporting components for Platform Provisioner in headless mode with tekton pipeline
# Globals:
# PIPELINE_GUI_DOCKER_IMAGE_REPO: the ECR repo to pull Platform Provisioner images
# PIPELINE_GUI_DOCKER_IMAGE_PATH: the ECR path to pull Platform Provisioner images
# PIPELINE_GUI_DOCKER_IMAGE_TAG: the ECR tag to pull Platform Provisioner images
# PIPELINE_GUI_DOCKER_IMAGE_USERNAME: the username for ECR to pull Platform Provisioner images
# PIPELINE_GUI_DOCKER_IMAGE_TOKEN: the read-only token for ECR to pull Platform Provisioner images
# PIPELINE_GUI_SERVICE_TYPE: the service type for the provisioner GUI
# PIPELINE_GUI_SERVICE_PORT: the service port for the provisioner GUI
# PIPELINE_NAMESPACE: the namespace to deploy the pipeline and provisioner GUI
# PLATFORM_PROVISIONER_PIPELINE_REPO: the repo to pull the pipeline and provisioner GUI helm charts
# PIPELINE_DOCKER_IMAGE: the docker image for the pipeline
# PIPELINE_SKIP_PROVISIONER_UI: true or other string if true, will skip installing platform-provisioner GUI
# PIPELINE_SKIP_TEKTON_DASHBOARD: true or other string if true, will skip installing tekton dashboard
# GITHUB_TOKEN: the token to access github that all pipeline can share
# TEKTON_PIPELINE_RELEASE: the tekton pipeline release version
# TEKTON_DASHBOARD_RELEASE: the tekton dashboard release version
# PIPELINE_CHART_VERSION_COMMON: the helm chart version for common-dependency pipeline
# PIPELINE_CHART_VERSION_GENERIC_RUNNER: the helm chart version for generic-runner pipeline
# PIPELINE_CHART_VERSION_HELM_INSTALL: the helm chart version for helm-install pipeline
# PIPELINE_CHART_VERSION_PROVISIONER_CONFIG_LOCAL: the helm chart version for provisioner-config-local
# PIPELINE_CHART_VERSION_PROVISIONER_UI: the helm chart version for platform-provisioner-ui
# Arguments:
# None
# Returns:
Expand Down Expand Up @@ -48,6 +59,8 @@ if [[ ${PIPELINE_SKIP_PROVISIONER_UI} == "false" ]]; then
[[ -z "${PIPELINE_GUI_DOCKER_IMAGE_REPO}" ]] && export PIPELINE_GUI_DOCKER_IMAGE_REPO=${PIPELINE_GUI_DOCKER_IMAGE_REPO:-"ghcr.io"}
[[ -z "${PIPELINE_GUI_DOCKER_IMAGE_PATH}" ]] && export PIPELINE_GUI_DOCKER_IMAGE_PATH=${PIPELINE_GUI_DOCKER_IMAGE_PATH:-"tibcosoftware/platform-provisioner/platform-provisioner-ui"}
[[ -z "${PIPELINE_GUI_DOCKER_IMAGE_TAG}" ]] && export PIPELINE_GUI_DOCKER_IMAGE_TAG=${PIPELINE_GUI_DOCKER_IMAGE_TAG:-"latest"}
[[ -z "${PIPELINE_GUI_SERVICE_TYPE}" ]] && export PIPELINE_GUI_SERVICE_TYPE=${PIPELINE_GUI_SERVICE_TYPE:-"ClusterIP"}
[[ -z "${PIPELINE_GUI_SERVICE_PORT}" ]] && export PIPELINE_GUI_SERVICE_PORT=${PIPELINE_GUI_SERVICE_PORT:-"80"}
fi

# The tekton version to install
Expand Down Expand Up @@ -170,6 +183,8 @@ helm upgrade --install -n "${PIPELINE_NAMESPACE}" platform-provisioner-ui platfo
--set "imagePullSecrets[0].name=${_image_pull_secret_name}" \
--set guiConfig.onPremMode=true \
--set guiConfig.pipelinesCleanUpEnabled=true \
--set service.type="${PIPELINE_GUI_SERVICE_TYPE}" \
--set service.port="${PIPELINE_GUI_SERVICE_PORT}" \
--set guiConfig.dataConfigMapName="provisioner-config-local-config"
if [[ $? -ne 0 ]]; then
echo "failed to install platform-provisioner-ui"
Expand Down
30 changes: 29 additions & 1 deletion docs/recipes/tp-base/tp-base-on-prem-https.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,12 @@ meta:
TP_TLS_CERT: ${GUI_TP_TLS_CERT}
TP_TLS_KEY: ${GUI_TP_TLS_KEY}
# storage
TP_STORAGE_CLASS: ${GUI_TP_STORAGE_CLASS:-"standard"} # hostpath for docker for mac, standard for minikube and kind, microk8s-hostpath for microk8s
TP_STORAGE_CLASS: ${GUI_TP_STORAGE_CLASS:-"standard"} # hostpath for docker desktop, standard for minikube and kind, microk8s-hostpath for microk8s
# third party
TP_EXT_NAMESPACE: tibco-ext
TP_INSTALL_PROVISIONER_UI: ${GUI_TP_INSTALL_PROVISIONER_UI:-"true"}
TP_PROVISIONER_UI_NAMESPACE: ${GUI_TP_PROVISIONER_UI_NAMESPACE:-"tekton-tasks"}
TP_PROVISIONER_UI_INGRESS_CLASSNAME: ${GUI_TP_PROVISIONER_UI_INGRESS_CLASSNAME:-"nginx"}
# CP DB setup env
TP_INSTALL_POSTGRES: ${GUI_TP_INSTALL_POSTGRES:-"true"}
TP_DB_USER_NAME: ${GUI_TP_DB_USER_NAME:-"postgres"} # TP_RDS_USERNAME in create-rds.sh
Expand Down Expand Up @@ -223,3 +226,28 @@ helmCharts:
flags:
createNamespace: true
timeout: 1h
- name: platform-provisioner-ui
version: ^1.0.0
namespace: ${TP_PROVISIONER_UI_NAMESPACE}
releaseName: platform-provisioner-ui
condition: ${TP_INSTALL_PROVISIONER_UI}
repo:
helm:
url: https://tibcosoftware.github.io/platform-provisioner
cluster:
names:
- ${TP_CLUSTER_NAME}
values:
keepPrevious: true
content: |
ingress:
enabled: true
className: ${TP_PROVISIONER_UI_INGRESS_CLASSNAME}
hosts:
- host: provisioner.${TP_DNS_DOMAIN}
paths:
- path: /
pathType: ImplementationSpecific
flags:
createNamespace: true
timeout: 1h
30 changes: 29 additions & 1 deletion docs/recipes/tp-base/tp-base-on-prem.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,12 @@ meta:
TP_INGRESS_SERVICE_TYPE: ${GUI_TP_INGRESS_SERVICE_TYPE:-"ClusterIP"} # LoadBalancer used for minikube with tunel, NodePort used for kind, ClusterIP used for kubectl port-forward
TP_INGRESS_USE_HOSTPORT: false # true for kind
# storage
TP_STORAGE_CLASS: ${GUI_TP_STORAGE_CLASS:-"standard"} # hostpath for docker for mac, standard for minikube and kind, microk8s-hostpath for microk8s
TP_STORAGE_CLASS: ${GUI_TP_STORAGE_CLASS:-"standard"} # hostpath for docker desktop, standard for minikube and kind, microk8s-hostpath for microk8s
# third party
TP_EXT_NAMESPACE: tibco-ext
TP_INSTALL_PROVISIONER_UI: ${GUI_TP_INSTALL_PROVISIONER_UI:-"true"}
TP_PROVISIONER_UI_NAMESPACE: ${GUI_TP_PROVISIONER_UI_NAMESPACE:-"tekton-tasks"}
TP_PROVISIONER_UI_INGRESS_CLASSNAME: ${GUI_TP_PROVISIONER_UI_INGRESS_CLASSNAME:-"nginx"}
# CP DB setup env
TP_INSTALL_POSTGRES: ${GUI_TP_INSTALL_POSTGRES:-"true"}
TP_DB_USER_NAME: ${GUI_TP_DB_USER_NAME:-"postgres"} # TP_RDS_USERNAME in create-rds.sh
Expand Down Expand Up @@ -163,3 +166,28 @@ helmCharts:
flags:
createNamespace: true
timeout: 1h
- name: platform-provisioner-ui
version: ^1.0.0
namespace: ${TP_PROVISIONER_UI_NAMESPACE}
releaseName: platform-provisioner-ui
condition: ${TP_INSTALL_PROVISIONER_UI}
repo:
helm:
url: https://tibcosoftware.github.io/platform-provisioner
cluster:
names:
- ${TP_CLUSTER_NAME}
values:
keepPrevious: true
content: |
ingress:
enabled: true
className: ${TP_PROVISIONER_UI_INGRESS_CLASSNAME}
hosts:
- host: provisioner.${TP_DNS_DOMAIN}
paths:
- path: /
pathType: ImplementationSpecific
flags:
createNamespace: true
timeout: 1h