Hey, Im using Kubernetes 1.20 .
Im applying a deployment that is failing because of a secret that does not exist. (the placeholders are filled by a script that generates random values which do not exist).
My question is does anyone might have a clue why every time that I apply this deployment. the replica set always has the same id for when it failed, and even after I remove the secret and it works it always uses the same replica id .
Does the replica set id has a meaning ?
Cluster information:
Kubernetes version: 1.20
Bare metal.
Installation method: kubeadm
the yaml:
apiVersion: v1
kind: List
metadata: {}
items:
- apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: missing-secret
name: <name>
namespace: <namespace>
spec:
selector:
matchLabels:
app: missing-secret
replicas: 2
revisionHistoryLimit: 3
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
creationTimestamp: null
labels:
app: missing-secret
spec:
containers:
- image: k8s.gcr.io/echoserver:1.4
imagePullPolicy: Always
name: <name>
env:
- name: <envvvarname>
valueFrom:
secretKeyRef:
name: <secret-name>
key: <secret-key>
resources:
limits:
cpu: 100m
memory: 40Mi
requests:
cpu: 70m
memory: 10Mi
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
dnsPolicy: ClusterFirst
restartPolicy: Always
schedulerName: default-scheduler
serviceAccount: sa-name
securityContext: {}
terminationGracePeriodSeconds: 30