Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Stevent-fei committed Oct 24, 2022
1 parent 09bcc8e commit 9bfb8b6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/infradriver/ssh_infradriver.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ func (d *SSHInfraDriver) GetHostIPListByRole(role string) []net.IP {
}

func (d *SSHInfraDriver) GetHostEnv(host net.IP) map[string]interface{} {
// Set env for each host
hostEnv := d.hostEnvMap[host.String()]
if _, ok := hostEnv[common.HostIP]; !ok {
hostEnv[common.HostIP] = host.String()
Expand All @@ -150,6 +151,8 @@ func (d *SSHInfraDriver) GetHostEnv(host net.IP) map[string]interface{} {
}

func (d *SSHInfraDriver) GetClusterEnv() map[string]interface{} {
// Set the default RegistryDomain and RegistryPort env,
// and override the env if the user specifies RegistryDomain and RegistryPort env
if _, ok := d.clusterEnv["RegistryDomain"]; !ok {
d.clusterEnv["RegistryDomain"] = common.DefaultRegistryDomain
}
Expand Down

0 comments on commit 9bfb8b6

Please sign in to comment.