-
Notifications
You must be signed in to change notification settings - Fork 1
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
Add custom values file for scalardb-graphql Helm chart #180
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good to me, but I have comments about tolerations
and podAntiAffinity
.
1. About tolerations
It seems that there is no configuration of tolerations
like scalardl-custom-values.yaml
and scalardb-custom-values.yaml
.
https://github.com/scalar-labs/scalar-kubernetes/blob/master/conf/scalardl-custom-values.yaml#L99-L103
https://github.com/scalar-labs/scalar-kubernetes/blob/master/conf/scalardb-custom-values.yaml#L86-L90
I think some non Scalar DB GraphQL Server pods (e.g. user application pod) will be deployed to the node group for Scalar DB GraphQL Server, if there is no configuration of tolerations
.
So, I think it is better to add tolerations
to this sample custom values file.
(Also, in this case, we need to add the section that explain about adding Taints
to the Kubernetes worker node in the deployment guide.)
What do you think?
2. About podAntiAffinity
It seems that there is no configuration of podAntiAffinity
like scalardl-custom-values.yaml
and scalardb-custom-values.yaml
.
https://github.com/scalar-labs/scalar-kubernetes/blob/master/conf/scalardb-custom-values.yaml#L101-L115
https://github.com/scalar-labs/scalar-kubernetes/blob/master/conf/scalardl-custom-values.yaml#L114-L128
I think several Scalar DB GraphQL pods will be deployed to the same one node, if there is no configuration of podAntiAffinity
.
So, I think it is better to add podAntiAffinity
to distribute pods within the Kubernetes cluster.
What do you think?
@kota2and3kan Thank you for the suggestion. I didn't fully understand how |
@kota2and3kan Sorry for the late reply. I have added a description about Taints in scalar-labs/scalardb-graphql#32. Please take a look. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
It worked well in my local environment!
-
tolerations
$ kubectl describe node minikube | grep Taints Taints: <none> $ kubectl describe node minikube-m02 | grep Taints Taints: kubernetes.io/app=scalardbgraphqlpool:NoSchedule
$ kubectl get pod -o wide NAME READY STATUS RESTARTS AGE IP NODE NOMINATED NODE READINESS GATES mysql-scalardb-0 1/1 Running 0 50m 172.17.0.4 minikube <none> <none> postgresql-scalardb-0 1/1 Running 0 50m 172.17.0.5 minikube <none> <none> scalardb-6644875756-28fld 1/1 Running 0 48m 172.17.0.7 minikube <none> <none> scalardb-envoy-84bf44bc5d-84c88 1/1 Running 0 48m 172.17.0.6 minikube <none> <none> scalardb-graphql-7db6cdd8b5-8596x 0/1 Running 0 2s 172.17.0.4 minikube-m02 <none> <none> scalardb-graphql-7db6cdd8b5-vg9k5 0/1 Running 0 3s 172.17.0.3 minikube-m02 <none> <none> scalardb-graphql-7db6cdd8b5-zls4b 0/1 Running 0 2s 172.17.0.2 minikube-m02 <none> <none>
- Scalar DB GraphQL pods run on
minikube-m02
and other pods run onminikube
. In other words, I was able to makeminikube-m02
dedicated node for Scalar DB GraphQL.
- Scalar DB GraphQL pods run on
-
podAntiAffinity (I use
requiredDuringSchedulingIgnoredDuringExecution
for testing.)$ kubectl get pod -o wide NAME READY STATUS RESTARTS AGE IP NODE NOMINATED NODE READINESS GATES mysql-scalardb-0 1/1 Running 0 52m 172.17.0.4 minikube <none> <none> postgresql-scalardb-0 1/1 Running 0 51m 172.17.0.5 minikube <none> <none> scalardb-6644875756-28fld 1/1 Running 0 49m 172.17.0.7 minikube <none> <none> scalardb-envoy-84bf44bc5d-84c88 1/1 Running 0 49m 172.17.0.6 minikube <none> <none> scalardb-graphql-7bf5c4744c-52gc4 0/1 Pending 0 2s <none> <none> <none> <none> scalardb-graphql-7bf5c4744c-qrcpv 0/1 Running 0 2s 172.17.0.2 minikube-m02 <none> <none> scalardb-graphql-7bf5c4744c-xfmtt 0/1 Pending 0 2s <none> <none> <none> <none>
- Only one Scalar DB GraphQL pod runs on one node.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a minor suggestion.
Other than that, LGTM! Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you!
Co-authored-by: Hiroyuki Yamada <mogwaing@gmail.com>
This PR adds a custom values file for scalardb-graphql Helm chart.
This file is going to be referenced from the deployment guide. scalar-labs/scalardb-graphql#18
Currently, it covers AWS only. The database configurations and the Ingress annotations for other services should be added when needed.