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

Use cluster name for resource creation #3

Closed
keyvaann opened this issue Dec 4, 2023 · 6 comments
Closed

Use cluster name for resource creation #3

keyvaann opened this issue Dec 4, 2023 · 6 comments

Comments

@keyvaann
Copy link
Collaborator

keyvaann commented Dec 4, 2023

S3 bucket names should be globally unique, values commonly used in ${var.environment} such as dev and prod won't be unique.

Edit: ${var.environment} is used in other places as well. I think its description and examples can be improved to suggest that it's name of the environment in general and not whether it's dev or prod. Or the value to be merged with ${var.eks_cluster_name}.

@keyvaann keyvaann changed the title Use cluster name for s3 bucket names Use cluster name for resource creation Dec 4, 2023
@baixiac
Copy link
Member

baixiac commented Dec 5, 2023

Alright, I can make ${var.eks_cluster_name} part of the names of the resources such as S3 buckets. The naming was based on the assumption that only one Radar K8s cluster would be created for each environment. And let's also not go down into the rabbit hole that multiple clusters could share the same bucket.

@keyvaann
Copy link
Collaborator Author

keyvaann commented Dec 5, 2023

Thanks! What do mean as environment? The AWS region or the environment variable?
I don't think multiple clusters can use the same bucket since it will mess up the data processing and potentially corrupt it.

@baixiac
Copy link
Member

baixiac commented Dec 5, 2023

By "environment", I meant dev, int, test, stage and prod from a development sense.

I don't think multiple clusters can use the same bucket since it will mess up the data processing and potentially corrupt it.

Generally speaking that's true but every so often int wants to pull test data to do some sanity check and test wants to pull live data (read-only access) to replicate a bug in prod. I think this is on a per-user/business basis.

@keyvaann
Copy link
Collaborator Author

keyvaann commented Dec 5, 2023

I see, in our use case at least, it's possible to have multiple clusters for different customers.

Generally speaking that's true but every so often int wants to pull test data to do some sanity check and test wants to pull live data (read-only access) to replicate a bug in prod. I think this is on a per-user/business basis.

Fair enough, I think that would be a manual and one in a while process and not a continuous bucket sharing of a 2 different prod clusters.

@baixiac
Copy link
Member

baixiac commented Dec 6, 2023

Indeed, continuous bucket sharing probably needs prefixes for organising objects belonging to different clusters.

The ${var.environment} is now removed from resource names and only used in DNS names and as cost-allocation tags. #7

@baixiac
Copy link
Member

baixiac commented Dec 7, 2023

Closed by #7.

@baixiac baixiac closed this as completed Dec 7, 2023
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

No branches or pull requests

2 participants