Skip to content

Commit

Permalink
Apply gofmt from go 1.11
Browse files Browse the repository at this point in the history
I'm assuming gofmt changed in go 1.11 to be stricter; these are the
changes that should allow gofmt checks to pass with go 1.11.
  • Loading branch information
justinsb committed Sep 14, 2018
1 parent d81ab2a commit 7b427d9
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 21 deletions.
14 changes: 7 additions & 7 deletions cloudmock/aws/mockautoscaling/group.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ func (m *MockAutoscaling) CreateAutoScalingGroup(input *autoscaling.CreateAutoSc
DefaultCooldown: input.DefaultCooldown,
DesiredCapacity: input.DesiredCapacity,
// EnabledMetrics: input.EnabledMetrics,
HealthCheckGracePeriod: input.HealthCheckGracePeriod,
HealthCheckType: input.HealthCheckType,
Instances: []*autoscaling.Instance{},
LaunchConfigurationName: input.LaunchConfigurationName,
LoadBalancerNames: input.LoadBalancerNames,
MaxSize: input.MaxSize,
MinSize: input.MinSize,
HealthCheckGracePeriod: input.HealthCheckGracePeriod,
HealthCheckType: input.HealthCheckType,
Instances: []*autoscaling.Instance{},
LaunchConfigurationName: input.LaunchConfigurationName,
LoadBalancerNames: input.LoadBalancerNames,
MaxSize: input.MaxSize,
MinSize: input.MinSize,
NewInstancesProtectedFromScaleIn: input.NewInstancesProtectedFromScaleIn,
PlacementGroup: input.PlacementGroup,
// Status: input.Status,
Expand Down
2 changes: 1 addition & 1 deletion nodeup/pkg/model/kubelet.go
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@ func (b *KubeletBuilder) buildMasterKubeletKubeconfig() (*nodetasks.File, error)

template := &x509.Certificate{
BasicConstraintsValid: true,
IsCA: false,
IsCA: false,
}

template.Subject = pkix.Name{
Expand Down
2 changes: 1 addition & 1 deletion pkg/pki/certificate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func TestGenerateCertificate(t *testing.T) {
KeyUsage: x509.KeyUsageCertSign | x509.KeyUsageCRLSign,
ExtKeyUsage: []x509.ExtKeyUsage{},
BasicConstraintsValid: true,
IsCA: true,
IsCA: true,
}

cert, err := SignNewCertificate(key, template, nil, nil)
Expand Down
20 changes: 10 additions & 10 deletions upup/pkg/fi/cloudup/apply_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,16 +380,16 @@ func (c *ApplyClusterCmd) Run() error {
"iamRolePolicy": &awstasks.IAMRolePolicy{},

// VPC / Networking
"dhcpOptions": &awstasks.DHCPOptions{},
"internetGateway": &awstasks.InternetGateway{},
"route": &awstasks.Route{},
"routeTable": &awstasks.RouteTable{},
"routeTableAssociation": &awstasks.RouteTableAssociation{},
"securityGroup": &awstasks.SecurityGroup{},
"securityGroupRule": &awstasks.SecurityGroupRule{},
"subnet": &awstasks.Subnet{},
"vpc": &awstasks.VPC{},
"ngw": &awstasks.NatGateway{},
"dhcpOptions": &awstasks.DHCPOptions{},
"internetGateway": &awstasks.InternetGateway{},
"route": &awstasks.Route{},
"routeTable": &awstasks.RouteTable{},
"routeTableAssociation": &awstasks.RouteTableAssociation{},
"securityGroup": &awstasks.SecurityGroup{},
"securityGroupRule": &awstasks.SecurityGroupRule{},
"subnet": &awstasks.Subnet{},
"vpc": &awstasks.VPC{},
"ngw": &awstasks.NatGateway{},
"vpcDHDCPOptionsAssociation": &awstasks.VPCDHCPOptionsAssociation{},

// ELB
Expand Down
2 changes: 1 addition & 1 deletion upup/pkg/fi/fitasks/keypair.go
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ func buildCertificateTemplateForType(certificateType string) (*x509.Certificate,

template := &x509.Certificate{
BasicConstraintsValid: true,
IsCA: false,
IsCA: false,
}

tokens := strings.Split(certificateType, ",")
Expand Down
2 changes: 1 addition & 1 deletion upup/pkg/fi/vfs_castore.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ func BuildCAX509Template() *x509.Certificate {
KeyUsage: x509.KeyUsageCertSign | x509.KeyUsageCRLSign,
ExtKeyUsage: []x509.ExtKeyUsage{},
BasicConstraintsValid: true,
IsCA: true,
IsCA: true,
}
return template
}
Expand Down

0 comments on commit 7b427d9

Please sign in to comment.