mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-24 19:38:02 +00:00
Added flag to set cluster class B network address for pods, add flag to disable allocation CIDRs for Pods. Fixed synchornization bug in NodeController registerNodes().
This commit is contained in:
committed by
CJ Cullen
parent
290c7b94ef
commit
e967ffd522
@@ -53,7 +53,9 @@ type GCECloud struct {
|
||||
projectID string
|
||||
zone string
|
||||
instanceID string
|
||||
networkName string
|
||||
|
||||
// We assume here that nodes and master are in the same network. TODO(cjcullen) Fix it.
|
||||
networkName string
|
||||
|
||||
// Used for accessing the metadata server
|
||||
metadataAccess func(string) (string, error)
|
||||
@@ -243,6 +245,7 @@ func waitForOp(op *compute.Operation, getOperation func() (*compute.Operation, e
|
||||
pollOp := op
|
||||
for pollOp.Status != "DONE" {
|
||||
var err error
|
||||
// TODO: add some backoff here.
|
||||
time.Sleep(time.Second)
|
||||
pollOp, err = getOperation()
|
||||
if err != nil {
|
||||
@@ -569,6 +572,7 @@ func (gce *GCECloud) Configure(name string, spec *api.NodeSpec) error {
|
||||
}
|
||||
return ErrMetadataConflict
|
||||
}
|
||||
// We are setting the metadata, so they can be picked-up by the configure-vm.sh script to start docker with the given CIDR for Pods.
|
||||
instance.Metadata.Items = append(instance.Metadata.Items,
|
||||
&compute.MetadataItems{
|
||||
Key: podCIDRMetadataKey,
|
||||
|
Reference in New Issue
Block a user