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

Also apply volumes and custom configs from spec to init containers #29

Conversation

sergicastro
Copy link
Collaborator

@sergicastro sergicastro commented Nov 12, 2024

Part of: https://github.com/tetrateio/tetrate/issues/23240

This PR applies the custom config map and the custom volumes from the Kubegres spec to the init containers from the stateful sets, as it does for the main containers.
It also makes failover to use the custom config map in case it contains the script to promote replicas.

This allows TSB to configure volumes containing the TLS certificates and custom scripts that execute replica initialization using the TLS certs to connect to the primary instance.

@sergicastro sergicastro marked this pull request as draft November 13, 2024 09:38
@sergicastro
Copy link
Collaborator Author

Detected an issue executing failover. Working on the fix.

@sergicastro sergicastro marked this pull request as ready for review November 13, 2024 16:05
@sergicastro
Copy link
Collaborator Author

The last commit fixes the issue in the failover, and also extends the tests by:

  • making the failover test to execute failover twice
  • adding a test using custom configs and executing the failover twice

nacx
nacx previously approved these changes Nov 14, 2024
@sergicastro sergicastro marked this pull request as draft November 14, 2024 10:01
@sergicastro
Copy link
Collaborator Author

I just found upgrade from older version with not custom-config is failing.
I want to fix it in the same PR, so holding until i push the fix with a test :)

@sergicastro sergicastro marked this pull request as ready for review November 19, 2024 18:43
@sergicastro
Copy link
Collaborator Author

The last commit fixes the problem with upgrading a volume from the base config to the custom config map. PTAL again @nacx

@sergicastro sergicastro merged commit 9f720b8 into tetrateio:release-v1.16.x Nov 20, 2024
7 checks passed
@sergicastro sergicastro deleted the volumes-and-configs-init-containers branch November 20, 2024 08:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants