mirror of https://github.com/kubernetes/kops.git
kubetest2: support specifying admin-access value
Otherwise I was getting my IPv6 address, which doesn't work well.
This commit is contained in:
parent
62b7ae0c49
commit
b04b5f556c
|
@ -55,6 +55,8 @@ type deployer struct {
|
|||
|
||||
ArtifactsDir string `flag:"-"`
|
||||
|
||||
AdminAccess string `flag:"admin-access" desc:"The CIDR to restrict kubernetes API access"`
|
||||
|
||||
BuildOptions *builder.BuildOptions
|
||||
}
|
||||
|
||||
|
|
|
@ -38,10 +38,15 @@ func (d *deployer) Up() error {
|
|||
return err
|
||||
}
|
||||
|
||||
adminAccess := d.AdminAccess
|
||||
if adminAccess == "" {
|
||||
adminAccess = publicIP
|
||||
}
|
||||
|
||||
args := []string{
|
||||
d.KopsBinaryPath, "create", "cluster",
|
||||
"--name", d.ClusterName,
|
||||
"--admin-access", publicIP,
|
||||
"--admin-access", adminAccess,
|
||||
"--cloud", d.CloudProvider,
|
||||
"--kubernetes-version", d.KubernetesVersion,
|
||||
"--master-count", "1",
|
||||
|
|
Loading…
Reference in New Issue