Skip to content

Commit

Permalink
Remove supfluous context
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisdoherty4 committed Oct 21, 2023
1 parent 14b5003 commit 1b6245b
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/createcluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ func (cc *createClusterOptions) createCluster(cmd *cobra.Command, _ []string) er
}
}

factory := dependencies.ForSpec(ctx, clusterSpec).WithExecutableMountDirs(dirs...).
factory := dependencies.ForSpec(clusterSpec).WithExecutableMountDirs(dirs...).

Check warning on line 179 in cmd/eksctl-anywhere/cmd/createcluster.go

View check run for this annotation

Codecov / codecov/patch

cmd/eksctl-anywhere/cmd/createcluster.go#L179

Added line #L179 was not covered by tests
WithBootstrapper().
WithCliConfig(cliConfig).
WithClusterManager(clusterSpec.Cluster, clusterManagerTimeoutOpts).
Expand Down
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/deletecluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ func (dc *deleteClusterOptions) deleteCluster(ctx context.Context) error {
return err
}

deps, err := dependencies.ForSpec(ctx, clusterSpec).WithExecutableMountDirs(dirs...).
deps, err := dependencies.ForSpec(clusterSpec).WithExecutableMountDirs(dirs...).

Check warning on line 111 in cmd/eksctl-anywhere/cmd/deletecluster.go

View check run for this annotation

Codecov / codecov/patch

cmd/eksctl-anywhere/cmd/deletecluster.go#L111

Added line #L111 was not covered by tests
WithBootstrapper().
WithCliConfig(cliConfig).
WithClusterManager(clusterSpec.Cluster, nil).
Expand Down
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/generatebundleconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func (gsbo *generateSupportBundleOptions) generateBundleConfig(ctx context.Conte
return nil, fmt.Errorf("unable to get cluster config from file: %v", err)
}

deps, err := dependencies.ForSpec(ctx, clusterSpec).
deps, err := dependencies.ForSpec(clusterSpec).
WithProvider(clusterConfigPath, clusterSpec.Cluster, cc.skipIpCheck, gsbo.hardwareFileName, false, gsbo.tinkerbellBootstrapIP, map[string]bool{}, nil).

Check warning on line 79 in cmd/eksctl-anywhere/cmd/generatebundleconfig.go

View check run for this annotation

Codecov / codecov/patch

cmd/eksctl-anywhere/cmd/generatebundleconfig.go#L78-L79

Added lines #L78 - L79 were not covered by tests
WithDiagnosticBundleFactory().
Build(ctx)
Expand Down
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/supportbundle.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func (csbo *createSupportBundleOptions) createBundle(ctx context.Context, since,
return fmt.Errorf("unable to get cluster config from file: %v", err)
}

deps, err := dependencies.ForSpec(ctx, clusterSpec).
deps, err := dependencies.ForSpec(clusterSpec).
WithProvider(csbo.fileName, clusterSpec.Cluster, cc.skipIpCheck, csbo.hardwareFileName, false, csbo.tinkerbellBootstrapIP, map[string]bool{}, nil).
WithDiagnosticBundleFactory().
Build(ctx)
Expand Down
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/upgradecluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ func (uc *upgradeClusterOptions) upgradeCluster(cmd *cobra.Command, args []strin
}
}

factory := dependencies.ForSpec(ctx, clusterSpec).WithExecutableMountDirs(dirs...).
factory := dependencies.ForSpec(clusterSpec).WithExecutableMountDirs(dirs...).

Check warning on line 144 in cmd/eksctl-anywhere/cmd/upgradecluster.go

View check run for this annotation

Codecov / codecov/patch

cmd/eksctl-anywhere/cmd/upgradecluster.go#L144

Added line #L144 was not covered by tests
WithBootstrapper().
WithCliConfig(cliConfig).
WithClusterManager(clusterSpec.Cluster, clusterManagerTimeoutOpts).
Expand Down
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/upgradeplancluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func (uc *upgradeClusterOptions) upgradePlanCluster(ctx context.Context) error {
return err
}

deps, err := dependencies.ForSpec(ctx, newClusterSpec).
deps, err := dependencies.ForSpec(newClusterSpec).

Check warning on line 67 in cmd/eksctl-anywhere/cmd/upgradeplancluster.go

View check run for this annotation

Codecov / codecov/patch

cmd/eksctl-anywhere/cmd/upgradeplancluster.go#L67

Added line #L67 was not covered by tests
WithClusterManager(newClusterSpec.Cluster, nil).
WithProvider(uc.fileName, newClusterSpec.Cluster, false, uc.hardwareCSVPath, uc.forceClean, uc.tinkerbellBootstrapIP, map[string]bool{}, uc.providerOptions).
WithGitOpsFlux(newClusterSpec.Cluster, newClusterSpec.FluxConfig, nil).
Expand Down
2 changes: 1 addition & 1 deletion cmd/eksctl-anywhere/cmd/validatecreatecluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func (valOpt *validateOptions) validateCreateCluster(cmd *cobra.Command, _ []str
if err != nil {
return err
}
deps, err := dependencies.ForSpec(ctx, clusterSpec).
deps, err := dependencies.ForSpec(clusterSpec).

Check warning on line 82 in cmd/eksctl-anywhere/cmd/validatecreatecluster.go

View check run for this annotation

Codecov / codecov/patch

cmd/eksctl-anywhere/cmd/validatecreatecluster.go#L82

Added line #L82 was not covered by tests
WithExecutableMountDirs(dirs...).
WithWriterFolder(tmpPath).
WithDocker().
Expand Down
2 changes: 1 addition & 1 deletion pkg/dependencies/factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ func (d *Dependencies) Close(ctx context.Context) error {
return nil
}

func ForSpec(ctx context.Context, clusterSpec *cluster.Spec) *Factory {
func ForSpec(clusterSpec *cluster.Spec) *Factory {

Check warning on line 131 in pkg/dependencies/factory.go

View workflow job for this annotation

GitHub Actions / lint

exported: exported function ForSpec should have comment or be unexported (revive)

Check warning on line 131 in pkg/dependencies/factory.go

View check run for this annotation

Codecov / codecov/patch

pkg/dependencies/factory.go#L131

Added line #L131 was not covered by tests
versionsBundle := clusterSpec.RootVersionsBundle()
eksaToolsImage := versionsBundle.Eksa.CliTools
return NewFactory().
Expand Down

0 comments on commit 1b6245b

Please sign in to comment.