Reputation: 873
I'm using a GKE. For single zone it is free of charge(only instance cost). For DEV we are using it but for another environment like QA/DEV/Production do we need separate GKE Cluster or inside the current GKE a different namespace will work ? which is the best way in cost and security
Upvotes: 0
Views: 468
Reputation: 129065
This depends on your requirements. Both options are viable.
environment like QA/DEV/Production do we need separate GKE Cluster
In a professional environment for a large enterprise, this would be different clusters in different VPC (one VPC per environment) and you might use separate projects as well, but not needed.
inside the current GKE a different namespace will work
this is cheaper, but you have less separation. Only you know what you need.
Upvotes: 1
Reputation: 1775
No. You can have a different namespaces within the same cluster for different environments. This would be cost effective.
If you are using nodeports you need to take care of the below points :
But nodeports have to be unique across same cluster. So if you're using nodeports to access your applications, you need different clusters(if you still want to have the same node ports across all environments. If not, you can use the same cluster with different namespaces. Eg. if u have app1 with nodeport 30077 in Cluster1 namespace1 (used as dev) you cannot have app1 deployed with nodeport 30077 in Cluster1 namespace2 (used as test) but you can have app1 deployed with nodeport 3xxxx (except already used port - eg. in this case 30077) in cluster1 namespace2
Upvotes: 0