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

Revamp config process #212

Conversation

ASBishop
Copy link
Contributor

@ASBishop ASBishop commented Jun 9, 2023

This is an implementation for cinder that's consistent with the Propose Service Bootstrap config design

This PR consists of 3 patches, the first of which contains the most technically relevant changes, followed by 2 more "cleanup" patches. When reviewing the first patch, if you see some "cruft" that should be cleaned up, bear in mind it might be handled in one of the subsequent patches.

ASBishop added 2 commits June 9, 2023 11:32
Stop using an init container to generate the snippet files that
configure each cinder service. Now, the contents are rendered
entirely by the controllers, and stored in secrets that can be
mounted directly into the /etc/cinder/cinder.conf.d directory.
Content, including scripts, previously stored in a configmap are
now stored in a corresponding secret.

NOTES:
- This patch deprecates the need for init containers, but they
  will be fully removed in a separate patch.
- The switch from using configmaps to secrets affects a lot of
  function and variable names, and comments. This is cosmetic,
  and will be cleaned up in a separate patch.

A total of 4 config snippet files are generated:
- 00-config.conf contains global settings that are common to every
  cinder service, including ones that are derived from deployment
  secrets (e.g. transport URL, database password, etc.)
- 01-config.conf contains the global customServiceConfig settings
  that apply to every cinder service.
- 02-config.conf contains the customServiceConfig settings that
  are specific to each service.
- 03-config.conf contains secrets specified by each service's
  customServiceConfigSecrets.

The 00 and 01 files are generated by the top-level cinder controller,
and each service's 02 and 03 files are generated by that service's
controller. Each service's controller generates a secret that
contains all 4 files, and uses a volume mount to map them directly
in the /etc/cinder/cinder.conf.d directory. Mounting the files
directly in that directory eliminates the need for kolla to copy
the files from a separate "merged" directory.
Init containers are no longer required now that the controllers
fully maintain the each service's config files.
@openshift-ci openshift-ci bot requested review from eharney and stuggi June 9, 2023 15:39
@openshift-ci openshift-ci bot added the approved label Jun 9, 2023
@ASBishop ASBishop requested review from Akrog and fmount and removed request for eharney and stuggi June 9, 2023 15:40
@ASBishop
Copy link
Contributor Author

/retest

This is a purely cosmetic change (nothing functional) to update
and/or remove all references to configmaps now that everything
is stored in secrets.
@ASBishop ASBishop force-pushed the revamp-config-process branch from ee097b8 to 47f9dc1 Compare June 13, 2023 21:21
Copy link
Contributor

@Akrog Akrog left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Jul 5, 2023
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 5, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Akrog, ASBishop

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot merged commit 710f05e into openstack-k8s-operators:main Jul 5, 2023
@ASBishop ASBishop deleted the revamp-config-process branch July 5, 2023 13:24
ASBishop pushed a commit to ASBishop/cinder-operator that referenced this pull request Mar 11, 2024
…rators/renovate/openstack-k8s-operators

Update openstack-k8s-operators
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.

3 participants