forked from kubeflow/kubeflow
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
make IAP optional for click-deploy app (kubeflow#1927)
* make IAP optional for click-deploy app * more * automate cloud shell * frontend edit following review feedbacks * add input check when user choose to setup IAP
- Loading branch information
1 parent
8e9ea86
commit ebca47d
Showing
5 changed files
with
176 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# To establish connection to your kubeflow cluster | ||
|
||
## Run following command in your cloud shell terminal | ||
|
||
**./conn.sh** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/bin/bash | ||
|
||
# conn.sh - establish connection to kubeflow cluster | ||
|
||
set -e # exit on error | ||
|
||
PROJECT_ID=project_id_placeholder | ||
ZONE=zone_placeholder | ||
DEPLOY_NAME=deploy_name_placeholder | ||
|
||
gcloud container clusters get-credentials ${DEPLOY_NAME} --zone ${ZONE} --project ${PROJECT_ID} | ||
|
||
echo "Checking load balancing resource" | ||
for i in $(seq 1 10) | ||
do kubectl get pods -n kubeflow --selector=service=ambassador --field-selector=status.phase=Running | grep -q 'Running' && break || sleep 10 | ||
done | ||
|
||
POD_NAME=$(kubectl get pods -n kubeflow --selector=service=ambassador --field-selector=status.phase=Running -o jsonpath="{.items[0].metadata.name}") | ||
|
||
echo "Load balancing now ready" | ||
echo "Your kubeflow service now accessible via: https://ssh.cloud.google.com/devshell/proxy?authuser=0&port=8081" | ||
kubectl port-forward -n kubeflow ${POD_NAME} 8081:80 |