Hi CKADers, quick questions
- Does anyone know the difference between these 2 fields in a pod spec:
serviceAccountName and which field to set out of these 2 while adding a serviceaccount to a pod as both have the same values as far as I noticed
- What’s the best way to include an already running pod (ARP) when creating a deployment. What I do is I add the
pod-template-hash label to the ARP, and the deployment always terminates some other pod. Is it possible that the ARP to which we just added the label may get terminated?
Hello, @Satyam Sareen
Both are the same. Only one difference is,
serviceAccount is deprecated and replaced with
[email protected]:~# kubectl explain pod.spec.serviceAccount
FIELD: serviceAccount <string>
DeprecatedServiceAccount is a depreciated alias for ServiceAccountName.
Deprecated: Use serviceAccountName instead.
AFAIK, even if you write
serviceAccount instead of
serviceAccountName. It will work. But follow the latest one.
Any answers for the 2nd question.