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

Fix trusted-bundle conflict in ES secret controller #3135

Merged
merged 15 commits into from
Jan 25, 2024

Conversation

caseydavenport
Copy link
Member

Description

This controller is a bit complicated, but it tries to manage a few things:

  • Creation of KeyPairs for ES and ES related components
  • Creation of a trusted bundle to use for ES and ES related components.

It needs to do this differently depending on:

  • If this is a single-tenant or multi-tenant system.
  • If using internal or external ES

The bug this PR fixes occurred when using external ES in a single-tenant system. In this case, we would attempt to write two trusted bundles into the tigera-elasticsearch Namespace with conflicting contents, resulting in the tigera-ca-bundle ConfigMap oscillating between two states.

We need to make sure that this code:

  • Generates only a single trusted bundle in single-tenant mode (regardless of internal / external ES)
  • Generates both a trusted bundle for the tigera-elasticsearch NS, as well as for each tenant in multi-tenant mode (only supported with external ES)

For PR author

  • Tests for change.
  • If changing pkg/apis/, run make gen-files
  • If changing versions, run make gen-versions

For PR reviewers

A note for code reviewers - all pull requests must have the following:

  • Milestone set according to targeted release.
  • Appropriate labels:
    • kind/bug if this is a bugfix.
    • kind/enhancement if this is a a new feature.
    • enterprise if this PR applies to Calico Enterprise only.

@caseydavenport caseydavenport force-pushed the casey-fix-cert-management branch from 9c7a1bf to 5cdf410 Compare January 23, 2024 19:31
Copy link
Member

@rene-dekker rene-dekker left a comment

Choose a reason for hiding this comment

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

lgtm

@caseydavenport caseydavenport merged commit 09c10f2 into tigera:master Jan 25, 2024
5 checks passed
@caseydavenport caseydavenport deleted the casey-fix-cert-management branch January 25, 2024 16:38
@danudey danudey modified the milestones: v1.33.0, v1.34.0 Jan 31, 2024
tmjd pushed a commit to tmjd/operator that referenced this pull request Feb 12, 2024
tmjd added a commit that referenced this pull request Feb 13, 2024
Fix trusted-bundle conflict in ES secret controller [pick #3135 r1.33]
@tmjd tmjd mentioned this pull request Jul 17, 2024
5 tasks
caseydavenport added a commit to caseydavenport/operator that referenced this pull request Jul 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants