Skip to content
This repository was archived by the owner on May 28, 2021. It is now read-only.

Remove extra injected environment variables. #185

Merged
merged 1 commit into from
Jul 17, 2018

Conversation

gianlucaborello
Copy link

Hi

In my setup, in certain circumstances I need to use the mysql-agent standalone, that is without relying on the operator.

This means that I have to manually create the manifests for the MySQL StatefulSet and Service, so it's in my best interest to keep those as clean as possible.

While doing the translation, I noticed that there seem to be a few environment variables that are injected into the containers but are not used. In particular:

  • MYSQL_CLUSTER_SERVICE_NAME is injected but I can't find in the whole history of the project a revision in which it was ever used.

  • MYSQL_CLUSTER_NAME, POD_NAMESPACE, REPLICATION_GROUP_SEEDS, MYSQL_CLUSTER_MULTI_MASTER are injected into the mysql container, but I can't find a reason for doing so since that's the standard mysql container which doesn't understand those variables, and it's the agent container that needs to consume them.

Were they left there in order to be used by a human operator to have better introspection into the components, or are they just a relic from the past? In my tests, everything works fine without injecting them (in my redacted manifests), but please keep in mind I haven't tested the backup/restore logic.

Thanks

Signed-off-by: Gianluca Borello <g.borello@gmail.com>
Copy link

@prydie prydie left a comment

Choose a reason for hiding this comment

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

Yep, these are artefacts of the initial implementation and at least one mistake. Change LGTM.

@prydie prydie merged commit 2c43a85 into oracle:master Jul 17, 2018
@gianlucaborello gianlucaborello deleted the fix-env branch July 17, 2018 20:13
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants