Markeen Rice-Wallace:
HI All, I’ve got an MYSQL error with the Bravos deployment in the Game of Pods Lab. It’s complaining that the secret env vars are incompatible for the configuration of the drupal-mysql deployment.
> NAME READY STATUS RESTARTS AGE
> drupal-mysql-6b64486999-rfqss 0/1 Error 1 16s
> controlplane $ kubectl logs drupal-mysql-6b64486999-rfqss
> 2021-03-29 11:11:56+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 5.7.33-1debian10 started.
> 2021-03-29 11:11:56+00:00 [Note] [Entrypoint]: Switching to dedicated user ‘mysql’
> 2021-03-29 11:11:56+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 5.7.33-1debian10 started.
> 2021-03-29 11:11:56+00:00 [ERROR] [Entrypoint]: MYSQL_USER=“root”, MYSQL_USER and MYSQL_PASSWORD are for configuring a regular user and cannot be used for the root user
> Remove MYSQL_USER=“root” and use one of the following to control the root user password:
> - MYSQL_ROOT_PASSWORD
> - MYSQL_ALLOW_EMPTY_PASSWORD
> - MYSQL_RANDOM_ROOT_PASSWORD
My Deployment manifest & Secret manifest.
apiVersion: v1
data:
MYSQL_DATABASE: ZHJ1cGFsLWRhdGFiYXNl
MYSQL_ROOT_PASSWORD: cm9vdF9wYXNzd29yZA==
MYSQL_USER: cm9vdA==
kind: Secret
metadata:
creationTimestamp: "2021-03-29T11:02:25Z"
name: drupal-mysql-secret
namespace: default
resourceVersion: "2784"
selfLink: /api/v1/namespaces/default/secrets/drupal-mysql-secret
uid: 3eb982c0-907e-11eb-bd67-0242ac110036
type: Opaque
---
apiVersion: apps/v1
kind: Deployment
metadata:
creationTimestamp: null
labels:
app: drupal-mysql
name: drupal-mysql
spec:
replicas: 1
selector:
matchLabels:
app: drupal-mysql
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
app: drupal-mysql
spec:
volumes:
- name: drupal-mysql-pvc
persistentVolumeClaim:
claimName: drupal-mysql-pvc
containers:
- image: mysql:5.7
name: mysql
envFrom:
- secretRef:
name: drupal-mysql-secret
volumeMounts:
- mountPath: "/var/lib/mysql"
subPath: "dbdata"
name: drupal-mysql-pvc