Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide a way to override operand image, env, and resources in CRD #1245

Merged
merged 3 commits into from
Jan 15, 2025

Conversation

MikeEdgar
Copy link
Member

@MikeEdgar MikeEdgar commented Nov 26, 2024

This change deprecates the existing images and env properties of the CRD and replaces them with per-container objects to specify a container image, env, and resources (cpu/memory).

Currently in the Console CR, API container ENVs and override images can be given like

spec:
  env:
  - name: SOME_ENVVAR
    value: "custom-value"
  images:
    api: example.com/myorg/my-api-image:1.0
    ui: example.com/myorg/my-ui-image:1.0

The new way with the change is:

spec:
  containers:
    api:
      spec:
        image: example.com/myorg/my-api-image:1.0
        resources:
          limits:
            cpu: 500m
            memory: 256Mi
        env:
        - name: SOME_ENVVAR
          value: "custom-value"
    ui:
      spec:
        image: example.com/myorg/my-ui-image:1.0
        resources:
          limits:
            cpu: 500m
            memory: 256Mi
        env:
        - name: SOME_ENVVAR_UI
          value: "custom-value"

Both sets of properties are still mapped to the console deployment, but the old properties are marked as deprecated in the CRD descriptions.

@MikeEdgar MikeEdgar modified the milestone: 0.5.0 Nov 26, 2024
@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch 4 times, most recently from 172ce81 to e731818 Compare December 10, 2024 16:06
@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch 3 times, most recently from 3f57c78 to 86863ae Compare December 19, 2024 18:44
@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch 3 times, most recently from 8268d19 to acfda91 Compare January 8, 2025 12:08
@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch 2 times, most recently from becb6a2 to ed01509 Compare January 9, 2025 21:41
@MikeEdgar MikeEdgar added this to the 0.6.0 milestone Jan 9, 2025
@MikeEdgar MikeEdgar added java Pull requests that update Java code ready for review Pull request is ready for a static review labels Jan 9, 2025
@MikeEdgar MikeEdgar requested a review from a team January 9, 2025 23:04
@MikeEdgar
Copy link
Member Author

@k-wall, I'm curious to get your thoughts/feedback on the proposed CRD format in the description.

@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch 3 times, most recently from 479e401 to 4be9903 Compare January 14, 2025 15:21
Copy link
Contributor

@jankalinic jankalinic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Looks good!

Copy link

@k-wall k-wall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks reasonable, I left one suggestion to consider.

@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch from 4be9903 to e019b19 Compare January 15, 2025 15:24
Signed-off-by: Michael Edgar <medgar@redhat.com>
Signed-off-by: Michael Edgar <medgar@redhat.com>
Signed-off-by: Michael Edgar <medgar@redhat.com>
@MikeEdgar MikeEdgar force-pushed the operand-container-overrides branch from e019b19 to cbb3573 Compare January 15, 2025 15:36
@MikeEdgar MikeEdgar merged commit 47b4d62 into streamshub:main Jan 15, 2025
5 checks passed
@MikeEdgar MikeEdgar deleted the operand-container-overrides branch January 15, 2025 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
java Pull requests that update Java code ready for review Pull request is ready for a static review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants