Charts locaux
This commit is contained in:
@@ -16,6 +16,8 @@ type HelmChart struct {
|
||||
Name string
|
||||
Chart string
|
||||
Version string
|
||||
Url string
|
||||
|
||||
Workspace string
|
||||
Opts string
|
||||
Values string
|
||||
@@ -39,12 +41,27 @@ func (this HelmChart) Install() (string, error) {
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
// existe := false
|
||||
|
||||
if existe {
|
||||
return "Existe déjà", nil
|
||||
}
|
||||
|
||||
msg := fmt.Sprintf("%s install %s %s %s --output json", bin, this.Name, this.Chart, this.Opts)
|
||||
ficChart := this.Chart
|
||||
// Recherche locale
|
||||
if _, err := os.Stat(ficChart); err != nil {
|
||||
} else {
|
||||
// Recherche voa le Workspace
|
||||
ficChart := filepath.Join(this.Workspace, this.Chart)
|
||||
if _, err := os.Stat(ficChart); err == nil {
|
||||
} else {
|
||||
if this.Url != "" {
|
||||
fmt.Println("============ 52 Télechargement", this.Url)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
msg := fmt.Sprintf("%s install %s %s %s --output json", bin, this.Name, ficChart, this.Opts)
|
||||
|
||||
if this.Version != "" {
|
||||
msg = fmt.Sprintf("%s --version %s", msg, this.Version)
|
||||
|
||||
Reference in New Issue
Block a user