Skip to content

Conversation

@thelabdude
Copy link
Contributor

@thelabdude thelabdude commented Aug 17, 2021

Fixes #308

Consolidated most of the TLS related utility code into a new file in the util package: solr_tls_util.go

All the TLS related config (env vars, annotations, initContainers, volumes/mounts) get appended to the config for a StatefulSet or Deployment in one step at the end vs. being infused at various places in GenerateStatefulSet and GenerateSolrPrometheusExporterDeployment. I like this approach because most of the TLS config is additive. There are a few places where we have to be careful about overriding previous settings (such as the entrypoint for the exporter when using the mountedServerTLSDir but that's only in a few small places).

There's also a lot of common logic for configuring the StatefulSet (for SolrClouds) and Deployment (for exporter), so I refactored the reusable parts into their own method.

@thelabdude thelabdude marked this pull request as draft August 17, 2021 20:18
…tween the StatefulSet and exporter Deployment
@thelabdude thelabdude force-pushed the issue-308-tls-refactor branch from b7e3a8c to b619b29 Compare August 18, 2021 16:52
@thelabdude thelabdude marked this pull request as ready for review August 18, 2021 17:07
Copy link
Contributor

@HoustonPutman HoustonPutman left a comment

Choose a reason for hiding this comment

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

I really like the new design, this looks good to me!

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.

Refactor TLS code

2 participants