Skip to content

Commit

Permalink
improve the expression of some comments
Browse files Browse the repository at this point in the history
  • Loading branch information
SataQiu committed Nov 1, 2018
1 parent 5a8f831 commit d32526f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cmd/kubeadm/app/apis/kubeadm/v1alpha3/defaults_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ package v1alpha3
const (
// DefaultCACertPath defines default location of CA certificate on Windows
DefaultCACertPath = "C:/etc/kubernetes/pki/ca.crt"
// DefaultSocketUrlScheme defines default socket url prefix
// DefaultUrlScheme defines default socket url prefix
DefaultUrlScheme = "tcp"
// DefaultCRISocket defines the default cri socket
DefaultCRISocket = "tcp://localhost:2375"
Expand Down
2 changes: 1 addition & 1 deletion cmd/kubeadm/app/apis/kubeadm/v1beta1/defaults_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ package v1beta1
const (
// DefaultCACertPath defines default location of CA certificate on Windows
DefaultCACertPath = "C:/etc/kubernetes/pki/ca.crt"
// DefaultSocketUrlScheme defines default socket url prefix
// DefaultUrlScheme defines default socket url prefix
DefaultUrlScheme = "tcp"
// DefaultCRISocket defines the default cri socket
DefaultCRISocket = "tcp://localhost:2375"
Expand Down
6 changes: 5 additions & 1 deletion cmd/kubeadm/app/util/config/joinconfiguration.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,11 @@ func SetJoinDynamicDefaults(cfg *kubeadmapi.JoinConfiguration) error {
return nil
}

// JoinConfigFileAndDefaultsToInternalConfig
// JoinConfigFileAndDefaultsToInternalConfig takes a path to a config file and a versioned configuration that can serve as the default config
// If cfgPath is specified, defaultversionedcfg will always get overridden. Otherwise, the default config (often populated by flags) will be used.
// Then the external, versioned configuration is defaulted and converted to the internal type.
// Right thereafter, the configuration is defaulted again with dynamic values (like IP addresses of a machine, etc)
// Lastly, the internal config is validated and returned.
func JoinConfigFileAndDefaultsToInternalConfig(cfgPath string, defaultversionedcfg *kubeadmapiv1beta1.JoinConfiguration) (*kubeadmapi.JoinConfiguration, error) {
internalcfg := &kubeadmapi.JoinConfiguration{}

Expand Down
2 changes: 1 addition & 1 deletion cmd/kubeadm/app/util/system/types_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ type KernelValidatorHelperImpl struct{}

var _ KernelValidatorHelper = &KernelValidatorHelperImpl{}

// GetKernelRelease returns the windows release version (ex. 10.0.14393) as a string
// GetKernelReleaseVersion returns the windows release version (ex. 10.0.14393) as a string
func (o *KernelValidatorHelperImpl) GetKernelReleaseVersion() (string, error) {
args := []string{"(Get-CimInstance Win32_OperatingSystem).Version"}
releaseVersion, err := exec.Command("powershell", args...).Output()
Expand Down

0 comments on commit d32526f

Please sign in to comment.