github.com/percona/percona-xtradb-cluster-operator@v1.14.0/e2e-tests/affinity/compare/statefulset_custom-pxc-k127.yml (about) 1 apiVersion: apps/v1 2 kind: StatefulSet 3 metadata: 4 generation: 1 5 name: custom-pxc 6 ownerReferences: 7 - controller: true 8 kind: PerconaXtraDBCluster 9 name: custom 10 spec: 11 persistentVolumeClaimRetentionPolicy: 12 whenDeleted: Retain 13 whenScaled: Retain 14 podManagementPolicy: OrderedReady 15 replicas: 3 16 revisionHistoryLimit: 10 17 selector: 18 matchLabels: 19 app.kubernetes.io/component: pxc 20 app.kubernetes.io/instance: custom 21 app.kubernetes.io/managed-by: percona-xtradb-cluster-operator 22 app.kubernetes.io/name: percona-xtradb-cluster 23 app.kubernetes.io/part-of: percona-xtradb-cluster 24 serviceName: custom-pxc 25 template: 26 metadata: 27 labels: 28 app.kubernetes.io/component: pxc 29 app.kubernetes.io/instance: custom 30 app.kubernetes.io/managed-by: percona-xtradb-cluster-operator 31 app.kubernetes.io/name: percona-xtradb-cluster 32 app.kubernetes.io/part-of: percona-xtradb-cluster 33 spec: 34 affinity: 35 nodeAffinity: 36 preferredDuringSchedulingIgnoredDuringExecution: 37 - preference: 38 matchExpressions: 39 - key: another-node-label-key 40 operator: In 41 values: 42 - another-node-label-value 43 weight: 1 44 requiredDuringSchedulingIgnoredDuringExecution: 45 nodeSelectorTerms: 46 - matchExpressions: 47 - key: kubernetes.io/e2e-az-name 48 operator: In 49 values: 50 - e2e-az1 51 - e2e-az2 52 podAffinity: 53 requiredDuringSchedulingIgnoredDuringExecution: 54 - labelSelector: 55 matchExpressions: 56 - key: security 57 operator: In 58 values: 59 - S1 60 topologyKey: failure-domain.beta.kubernetes.io/zone 61 podAntiAffinity: 62 preferredDuringSchedulingIgnoredDuringExecution: 63 - podAffinityTerm: 64 labelSelector: 65 matchExpressions: 66 - key: security 67 operator: In 68 values: 69 - S2 70 topologyKey: kubernetes.io/hostname 71 weight: 100 72 containers: 73 - args: 74 - mysqld 75 command: 76 - /var/lib/mysql/pxc-entrypoint.sh 77 env: 78 - name: PXC_SERVICE 79 value: custom-pxc-unready 80 - name: MONITOR_HOST 81 value: '%' 82 - name: MYSQL_ROOT_PASSWORD 83 valueFrom: 84 secretKeyRef: 85 key: root 86 name: internal-custom 87 - name: XTRABACKUP_PASSWORD 88 valueFrom: 89 secretKeyRef: 90 key: xtrabackup 91 name: internal-custom 92 - name: MONITOR_PASSWORD 93 valueFrom: 94 secretKeyRef: 95 key: monitor 96 name: internal-custom 97 - name: OPERATOR_ADMIN_PASSWORD 98 valueFrom: 99 secretKeyRef: 100 key: operator 101 name: internal-custom 102 - name: LIVENESS_CHECK_TIMEOUT 103 value: "5" 104 - name: READINESS_CHECK_TIMEOUT 105 value: "15" 106 - name: DEFAULT_AUTHENTICATION_PLUGIN 107 value: mysql_native_password 108 envFrom: 109 - secretRef: 110 name: custom-env-vars-pxc 111 optional: true 112 imagePullPolicy: Always 113 livenessProbe: 114 exec: 115 command: 116 - /var/lib/mysql/liveness-check.sh 117 failureThreshold: 3 118 initialDelaySeconds: 300 119 periodSeconds: 10 120 successThreshold: 1 121 timeoutSeconds: 5 122 name: pxc 123 ports: 124 - containerPort: 3306 125 name: mysql 126 protocol: TCP 127 - containerPort: 4444 128 name: sst 129 protocol: TCP 130 - containerPort: 4567 131 name: write-set 132 protocol: TCP 133 - containerPort: 4568 134 name: ist 135 protocol: TCP 136 - containerPort: 33062 137 name: mysql-admin 138 protocol: TCP 139 - containerPort: 33060 140 name: mysqlx 141 protocol: TCP 142 readinessProbe: 143 exec: 144 command: 145 - /var/lib/mysql/readiness-check.sh 146 failureThreshold: 5 147 initialDelaySeconds: 15 148 periodSeconds: 30 149 successThreshold: 1 150 timeoutSeconds: 15 151 resources: 152 limits: 153 cpu: "1" 154 memory: 1G 155 requests: 156 cpu: 600m 157 memory: 1G 158 terminationMessagePath: /dev/termination-log 159 terminationMessagePolicy: File 160 volumeMounts: 161 - mountPath: /var/lib/mysql 162 name: datadir 163 - mountPath: /etc/percona-xtradb-cluster.conf.d 164 name: config 165 - mountPath: /tmp 166 name: tmp 167 - mountPath: /etc/mysql/ssl 168 name: ssl 169 - mountPath: /etc/mysql/ssl-internal 170 name: ssl-internal 171 - mountPath: /etc/mysql/mysql-users-secret 172 name: mysql-users-secret-file 173 - mountPath: /etc/my.cnf.d 174 name: auto-config 175 - mountPath: /etc/mysql/vault-keyring-secret 176 name: vault-keyring-secret 177 - mountPath: /etc/mysql/init-file 178 name: mysql-init-file 179 dnsPolicy: ClusterFirst 180 initContainers: 181 - command: 182 - /pxc-init-entrypoint.sh 183 imagePullPolicy: Always 184 name: pxc-init 185 resources: 186 limits: 187 cpu: 50m 188 memory: 50M 189 terminationMessagePath: /dev/termination-log 190 terminationMessagePolicy: File 191 volumeMounts: 192 - mountPath: /var/lib/mysql 193 name: datadir 194 restartPolicy: Always 195 schedulerName: default-scheduler 196 securityContext: 197 fsGroup: 1001 198 supplementalGroups: 199 - 1001 200 serviceAccount: default 201 serviceAccountName: default 202 terminationGracePeriodSeconds: 600 203 volumes: 204 - emptyDir: {} 205 name: tmp 206 - configMap: 207 defaultMode: 420 208 name: custom-pxc 209 optional: true 210 name: config 211 - name: ssl-internal 212 secret: 213 defaultMode: 420 214 optional: true 215 secretName: custom-ssl-internal 216 - name: ssl 217 secret: 218 defaultMode: 420 219 optional: false 220 secretName: some-name-ssl 221 - configMap: 222 defaultMode: 420 223 name: auto-custom-pxc 224 optional: true 225 name: auto-config 226 - name: vault-keyring-secret 227 secret: 228 defaultMode: 420 229 optional: true 230 secretName: custom-vault 231 - name: mysql-users-secret-file 232 secret: 233 defaultMode: 420 234 optional: false 235 secretName: internal-custom 236 - name: mysql-init-file 237 secret: 238 defaultMode: 420 239 optional: true 240 secretName: custom-mysql-init 241 updateStrategy: 242 rollingUpdate: 243 partition: 0 244 type: RollingUpdate 245 volumeClaimTemplates: 246 - metadata: 247 name: datadir 248 spec: 249 accessModes: 250 - ReadWriteOnce 251 resources: 252 requests: 253 storage: 2Gi 254 status: 255 phase: Pending