You've already forked sap-jenkins-library
mirror of
https://github.com/SAP/jenkins-library.git
synced 2025-07-15 01:34:38 +02:00
add --kube-context to uninstall command (#4999)
This commit is contained in:
@ -296,6 +296,9 @@ func (h *HelmExecute) RunHelmUninstall() error {
|
|||||||
if len(h.config.Namespace) <= 0 {
|
if len(h.config.Namespace) <= 0 {
|
||||||
return fmt.Errorf("namespace has not been set, please configure namespace parameter")
|
return fmt.Errorf("namespace has not been set, please configure namespace parameter")
|
||||||
}
|
}
|
||||||
|
if len(h.config.KubeContext) > 0 {
|
||||||
|
helmParams = append(helmParams, "--kube-context", h.config.KubeContext)
|
||||||
|
}
|
||||||
helmParams = append(helmParams, "--namespace", h.config.Namespace)
|
helmParams = append(helmParams, "--namespace", h.config.Namespace)
|
||||||
if h.config.HelmDeployWaitSeconds > 0 {
|
if h.config.HelmDeployWaitSeconds > 0 {
|
||||||
helmParams = append(helmParams, "--wait", "--timeout", fmt.Sprintf("%vs", h.config.HelmDeployWaitSeconds))
|
helmParams = append(helmParams, "--wait", "--timeout", fmt.Sprintf("%vs", h.config.HelmDeployWaitSeconds))
|
||||||
|
Reference in New Issue
Block a user