Skip to content

Commit

Permalink
Revert job image override for some components (#344)
Browse files Browse the repository at this point in the history
  • Loading branch information
l0kix2 authored Sep 13, 2024
1 parent b28e45a commit dce9397
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions pkg/components/strawberry_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ func NewStrawberryController(
dataNodes []Component) *StrawberryController {
resource := ytsaurus.GetResource()

// TODO: strawberry has a different image and can't be nil/fallback on CoreImage.
image := resource.Spec.CoreImage
if resource.Spec.StrawberryController.Image != nil {
image = *resource.Spec.StrawberryController.Image
Expand Down Expand Up @@ -83,7 +84,7 @@ func NewStrawberryController(
ytsaurus.GetResource().Spec.ImagePullSecrets,
"user",
consts.ClientConfigFileName,
getImageWithDefault(resource.Spec.StrawberryController.Image, resource.Spec.CoreImage),
resource.Spec.CoreImage,
cfgen.GetNativeClientConfig,
getTolerationsWithDefault(resource.Spec.StrawberryController.Tolerations, resource.Spec.Tolerations),
getNodeSelectorWithDefault(resource.Spec.StrawberryController.NodeSelector, resource.Spec.NodeSelector),
Expand All @@ -95,7 +96,7 @@ func NewStrawberryController(
resource.Spec.ImagePullSecrets,
"cluster",
ChytInitClusterJobConfigFileName,
getImageWithDefault(resource.Spec.StrawberryController.Image, resource.Spec.CoreImage),
resource.Spec.CoreImage,
cfgen.GetChytInitClusterConfig,
getTolerationsWithDefault(resource.Spec.StrawberryController.Tolerations, resource.Spec.Tolerations),
getNodeSelectorWithDefault(resource.Spec.StrawberryController.NodeSelector, resource.Spec.NodeSelector),
Expand Down
2 changes: 1 addition & 1 deletion pkg/components/ui.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func NewUI(cfgen *ytconfig.Generator, ytsaurus *apiproxy.Ytsaurus, master Compon
resource.Spec.ImagePullSecrets,
"default",
consts.ClientConfigFileName,
getImageWithDefault(resource.Spec.UI.Image, resource.Spec.CoreImage),
resource.Spec.CoreImage,
cfgen.GetNativeClientConfig,
getTolerationsWithDefault(resource.Spec.UI.Tolerations, resource.Spec.Tolerations),
getNodeSelectorWithDefault(resource.Spec.UI.NodeSelector, resource.Spec.NodeSelector),
Expand Down

0 comments on commit dce9397

Please sign in to comment.