StringInSlice
This commit is contained in:
parent
a1af83689d
commit
550675a4aa
@ -98,7 +98,7 @@ func (this *InstallClass) InstallCharts(modules []string) (error) {
|
|||||||
|
|
||||||
for _, v := range this.charts {
|
for _, v := range this.charts {
|
||||||
for _, v1 := range v.Charts {
|
for _, v1 := range v.Charts {
|
||||||
if len(modules) == 0 || stringInSlice(v1.Name, modules) {
|
if len(modules) == 0 || utils.StringInSlice(v1.Name, modules) {
|
||||||
wg.Add(1)
|
wg.Add(1)
|
||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
@ -112,16 +112,6 @@ func (this *InstallClass) InstallCharts(modules []string) (error) {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func stringInSlice(a string, list []string) bool {
|
|
||||||
for _, b := range list {
|
|
||||||
if b == a {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
func (this *InstallClass) installChart(helm_bin string, kubectl_bin string, chart chart.ChartData) {
|
func (this *InstallClass) installChart(helm_bin string, kubectl_bin string, chart chart.ChartData) {
|
||||||
|
|
||||||
log.Log().Info().Msg(fmt.Sprintf(" << Chart : %s ", chart.Name))
|
log.Log().Info().Msg(fmt.Sprintf(" << Chart : %s ", chart.Name))
|
||||||
|
Loading…
Reference in New Issue
Block a user