I am trying to create a Jenkins pipeline with active choice parameter options populated with GKE Cluster namespaces.
I can Run a single shell command and get output with this def namespaces = "kubectl get ns".execute() namespaces.waitFor() def namespace_string = namespaces.text But or this usecase I need to execute all below three shell commands in one process(authenticate cluster, switch to cluster, get namespaces) but seems they are not running in the same process "sudo gcloud auth activate-service-account --key-file=key_file.json" "gcloud container clusters get-credentials $CLUSTER --region $REGION --project $PROJECT" "kubectl get ns" Can anyone help with this? Please note that this is for populating active choice list. Thanks Sam -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/6e03dab4-5fb8-4833-a3c9-e8256198792bn%40googlegroups.com.
