Set default name for resources#97
Merged
Merged
Conversation
Member
I can confirm changing service names will break service discovery. We have way too many magic default env var e.g. 👍 let's just don't touch it. changing PVC name should be fine, but there's no good reason to do it, so let's leave it. |
michaellzc
approved these changes
Apr 6, 2022
| defaultTag: 3.38.0@sha256:246c3d82072511f376049762056a3c82fce5dbc4a00f29f10f64373b5fe0a9a9 | ||
| # -- Docker image name for the `cadvisor` image | ||
| name: "cadvisor" | ||
| # -- Name used by resources. Does not affect service names or PVCs. |
Contributor
Author
There was a problem hiding this comment.
Unfortunately, because name is a string it gets automatically added to the docs and there's no way to hide this.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Alternate implementation of #94 - sets a default name for all services so that we can easily reference resources.
The second commit updates most resources to use this default name, instead of a hardcoded version. I'm on the fence about how valuable this is.
Not included: service names and persistentVolumeClaim names remain hardcoded, instead of referencing the variable. I'm unclear what impact changing a service name would have on Sourcegraph's service discovery (most likely we can work around it by setting environment variables, but it's easier to avoid creating this problem). For PVC's, it seems risky to change the name if it had previously been created.
Checklist
Test plan
No change to rendered output before/after using default values.