mirror of
https://github.com/helm/helm.git
synced 2026-04-15 21:59:50 -04:00
added option --insecure-skip-tls-verify for helm pull, addresses #7875
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
This commit is contained in:
parent
c0edc586c5
commit
918deeef18
3 changed files with 12 additions and 9 deletions
|
|
@ -49,6 +49,7 @@ func addChartPathOptionsFlags(f *pflag.FlagSet, c *action.ChartPathOptions) {
|
|||
f.StringVar(&c.Password, "password", "", "chart repository password where to locate the requested chart")
|
||||
f.StringVar(&c.CertFile, "cert-file", "", "identify HTTPS client using this SSL certificate file")
|
||||
f.StringVar(&c.KeyFile, "key-file", "", "identify HTTPS client using this SSL key file")
|
||||
f.BoolVar(&c.InsecureSkipTLSverify, "insecure-skip-tls-verify", false, "skip tls certificate checks for the chart download")
|
||||
f.StringVar(&c.CaFile, "ca-file", "", "verify certificates of HTTPS-enabled servers using this CA bundle")
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -104,15 +104,16 @@ type Install struct {
|
|||
|
||||
// ChartPathOptions captures common options used for controlling chart paths
|
||||
type ChartPathOptions struct {
|
||||
CaFile string // --ca-file
|
||||
CertFile string // --cert-file
|
||||
KeyFile string // --key-file
|
||||
Keyring string // --keyring
|
||||
Password string // --password
|
||||
RepoURL string // --repo
|
||||
Username string // --username
|
||||
Verify bool // --verify
|
||||
Version string // --version
|
||||
CaFile string // --ca-file
|
||||
CertFile string // --cert-file
|
||||
KeyFile string // --key-file
|
||||
InsecureSkipTLSverify bool // --insecure-skip-verify
|
||||
Keyring string // --keyring
|
||||
Password string // --password
|
||||
RepoURL string // --repo
|
||||
Username string // --username
|
||||
Verify bool // --verify
|
||||
Version string // --version
|
||||
}
|
||||
|
||||
// NewInstall creates a new Install object with the given configuration.
|
||||
|
|
|
|||
|
|
@ -64,6 +64,7 @@ func (p *Pull) Run(chartRef string) (string, error) {
|
|||
Options: []getter.Option{
|
||||
getter.WithBasicAuth(p.Username, p.Password),
|
||||
getter.WithTLSClientConfig(p.CertFile, p.KeyFile, p.CaFile),
|
||||
getter.WithInsecureSkipVerifyTLS(p.InsecureSkipTLSverify),
|
||||
},
|
||||
RepositoryConfig: p.Settings.RepositoryConfig,
|
||||
RepositoryCache: p.Settings.RepositoryCache,
|
||||
|
|
|
|||
Loading…
Reference in a new issue