Move messaging configuration to file and deprecate deployMessagingService flag#1041
Move messaging configuration to file and deprecate deployMessagingService flag#1041nasark wants to merge 2 commits intoManageIQ:masterfrom
Conversation
|
@nasark unrecognized command 'enhancement', ignoring... Accepted commands are: add_label, add_reviewer, request_review, assign, close_issue, cross_repo_test, move_issue, remove_label, rm_label, remove_reviewer, set_milestone, unassign |
|
@miq-bot add_label quinteros/yes? |
|
Checked commits nasark/manageiq-pods@6c880dd~...21cd053 with ruby 2.7.8, rubocop 1.56.3, haml-lint 0.51.0, and yamllint |
| hostName := string(secret.Data["hostname"]) | ||
| if hostName != "manageiq-kafka-bootstrap" { |
There was a problem hiding this comment.
I followed the same methodology we use for postgresql but in this case the hostname also depends on cr.Spec.AppName. Would this be an issue? For example if a user decides to change the default app name for some reason then this wouldn't work, however this allows us to not deploy upstream kafka in the downstream scenario
| messaging_hostname=${MESSAGING_HOSTNAME:-$messaging_hostname_file} | ||
| messaging_hostname=${messaging_hostname:-localhost} | ||
| messaging_username=${MESSAGING_USERNAME:-$messaging_username_file} | ||
| messaging_password=${MESSAGING_PASSWORD:-$messaging_password_file} | ||
| messaging_port=${MESSAGING_PORT:-$messaging_port_file} | ||
| messaging_port=${messaging_port:-9093} | ||
| messaging_sasl_mechanism=${MESSAGING_SASL_MECHANISM:-$messaging_sasl_mechanism_file} |
There was a problem hiding this comment.
Since the env vars won't be used, should they be removed from these conditional assignments? I see that the database env vars are still checked in these conditional assignments https://github.com/ManageIQ/manageiq-pods/blob/master/images/manageiq-base/container-assets/container_env#L12-L20 so I followed suite but didn't understand the reasoning
There was a problem hiding this comment.
We kept them more as a convenience for developers - if you run it locally, it's just a lot easier to pass them as -e on the command line
| [[ -f /run/secrets/messaging/MESSAGING_SASL_MECHANISM ]] && messaging_sasl_mechanism_file=$(cat /run/secrets/messaging/MESSAGING_SASL_MECHANISM) | ||
| [[ -f /etc/pki/ca-trust/source/anchors/root.crt ]] && messaging_ca_path=/etc/pki/ca-trust/source/anchors/root.crt | ||
| messaging_hostname=${MESSAGING_HOSTNAME:-$messaging_hostname_file} | ||
| messaging_hostname=${messaging_hostname:-localhost} |
There was a problem hiding this comment.
Is this right? I thought localhost didn't work?
There was a problem hiding this comment.
It should probably default to the name of the service used to reach kafka
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
6 similar comments
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
|
This pull request has been automatically marked as stale because it has not been updated for at least 3 months. If these changes are still valid, please remove the |
cr.Spec.AppName-user->cr.Spec.AppName-kafka-adminso that upstream and downstream can both usefunc MessagingEnvSecretcr.Spec.DeployMessagingServiceDepends on:
@miq-bot assign @bdunne
@miq-bot add_reviewer @Fryguy