"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "pkg/controllers/management/node/controller.go" between
rancher-2.5.6.tar.gz and rancher-2.5.7.tar.gz

About: Rancher provides a container management platform that makes it easy to run Kubernetes everywhere, meet IT requirements, and empower DevOps teams.

controller.go  (rancher-2.5.6):controller.go  (rancher-2.5.7)
skipping to change at line 446 skipping to change at line 446
return errors.Wrap(err, string(output)) return errors.Wrap(err, string(output))
} }
return nil return nil
} }
// authenticateRegistry authenticates the machine to a private registry if one i s defined on the cluster // authenticateRegistry authenticates the machine to a private registry if one i s defined on the cluster
// this enables the agent image to be pulled from the private registry // this enables the agent image to be pulled from the private registry
func (m *Lifecycle) authenticateRegistry(nodeDir string, node *v3.Node, cluster *v3.Cluster) error { func (m *Lifecycle) authenticateRegistry(nodeDir string, node *v3.Node, cluster *v3.Cluster) error {
reg := util.GetPrivateRepo(cluster) reg := util.GetPrivateRepo(cluster)
if reg == nil { // if there is no private registry defined or there is a registry without
return nil // if there is no private registry defined, return sin credentials, return since auth is not needed
ce auth is not needed if reg == nil || reg.User == "" || reg.Password == "" {
return nil
} }
logrus.Infof("[node-controller-rancher-machine] private registry detected , authenticating %s to %s", node.Spec.RequestedHostname, reg.URL) logrus.Infof("[node-controller-rancher-machine] private registry detected , authenticating %s to %s", node.Spec.RequestedHostname, reg.URL)
login := clusterregistrationtokens.LoginCommand(*reg) login := clusterregistrationtokens.LoginCommand(*reg)
args := buildLoginCommand(node, login) args := buildLoginCommand(node, login)
cmd, err := buildCommand(nodeDir, node, args) cmd, err := buildCommand(nodeDir, node, args)
if err != nil { if err != nil {
return err return err
} }
 End of changes. 1 change blocks. 
3 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)