update runPlaybook function
This commit is contained in:
@@ -1961,7 +1961,7 @@ releases:
|
|||||||
server.insecure: true
|
server.insecure: true
|
||||||
|
|
||||||
secret:
|
secret:
|
||||||
argocdServerAdminPassword: $2a$10$vyI/s19oGdrz9rtPVKsZeuXIdPhQQcUzNcn/soL160xBFmvraA3Za
|
argocdServerAdminPassword: $2a$10$uVEAEmc8bmtQYsa3206a7OkI5oHkNWluS9s5szXsNUsgmKvY2jGZy
|
||||||
|
|
||||||
repositories:
|
repositories:
|
||||||
# add default helm-repository from harbor
|
# add default helm-repository from harbor
|
||||||
|
|||||||
@@ -1,16 +1,13 @@
|
|||||||
package kubespray
|
package kubespray
|
||||||
|
|
||||||
func InstallCluster(tags string) {
|
func InstallCluster(tags string) {
|
||||||
ansiblePlaybookOptions := getPlaybookParameters(tags)
|
runPlaybook("kubespray/project/cluster.yml", tags)
|
||||||
runPlaybook("kubespray/project/cluster.yml", ansiblePlaybookOptions)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func UpgradeCluster(tags string) {
|
func UpgradeCluster(tags string) {
|
||||||
ansiblePlaybookOptions := getPlaybookParameters(tags)
|
runPlaybook("kubespray/project/upgrade_cluster.yml", tags)
|
||||||
runPlaybook("kubespray/project/upgrade_cluster.yml", ansiblePlaybookOptions)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func ResetCluster() {
|
func ResetCluster() {
|
||||||
ansiblePlaybookOptions := getPlaybookParameters("reset")
|
runPlaybook("kubespray/project/reset.yml", "reset")
|
||||||
runPlaybook("kubespray/project/reset.yml", ansiblePlaybookOptions)
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -55,7 +55,8 @@ func CopyK8SAdminConfig(pathInDataDir string) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func runPlaybook(playbookPath string, playbookOptions playbook.AnsiblePlaybookOptions) {
|
func runPlaybook(playbookPath string, tags string) {
|
||||||
|
playbookOptions := getPlaybookParameters(tags)
|
||||||
playbookCmd := playbook.NewAnsiblePlaybookCmd(
|
playbookCmd := playbook.NewAnsiblePlaybookCmd(
|
||||||
playbook.WithPlaybooks(playbookPath),
|
playbook.WithPlaybooks(playbookPath),
|
||||||
playbook.WithPlaybookOptions(&playbookOptions),
|
playbook.WithPlaybookOptions(&playbookOptions),
|
||||||
|
|||||||
Reference in New Issue
Block a user