Closed davidshare closed 2 years ago
@davidshare
Can you kubectl describe
the deployment to see how the template has been generated ?
Did the secret you created is in the same namespace with metabase ?
Thanks @pmint93 - this is the description of the deployment
kubectl describe deployment metabase -n metabase
Name: metabase
Namespace: metabase
CreationTimestamp: Tue, 15 Feb 2022 12:52:14 +0100
Labels: app=metabase
app.kubernetes.io/managed-by=Helm
chart=metabase-1.4.0
heritage=Helm
release=metabase
Annotations: deployment.kubernetes.io/revision: 4
meta.helm.sh/release-name: metabase
meta.helm.sh/release-namespace: metabase
Selector: app=metabase
Replicas: 1 desired | 1 updated | 2 total | 1 available | 1 unavailable
StrategyType: RollingUpdate
MinReadySeconds: 0
RollingUpdateStrategy: 25% max unavailable, 25% max surge
Pod Template:
Labels: app=metabase
release=metabase
Annotations: checksum/config: ebbf78f5d3e95533542f724dd587556c25ab0764cea0cbeda62a482762698377
Service Account: default
Containers:
metabase:
Image: metabase/metabase:v0.41.6
Port: 3000/TCP
Host Port: 0/TCP
Liveness: http-get http://:3000/ delay=120s timeout=30s period=10s #success=1 #failure=6
Readiness: http-get http://:3000/ delay=30s timeout=3s period=5s #success=1 #failure=3
Environment:
MB_JETTY_HOST: 0.0.0.0
MB_JETTY_PORT: 3000
MB_DB_TYPE: postgres
MB_DB_CONNECTION_URI: <set to the key 'connectionURI' in secret 'metabase-secrets'> Optional: false
MB_PASSWORD_COMPLEXITY: normal
MB_PASSWORD_LENGTH: 6
JAVA_TIMEZONE: UTC
MB_EMOJI_IN_LOGS: true
MB_COLORIZE_LOGS: true
Mounts: <none>
Volumes: <none>
Conditions:
Type Status Reason
---- ------ ------
Available True MinimumReplicasAvailable
Progressing True ReplicaSetUpdated
OldReplicaSets: metabase-7946cbc7bf (1/1 replicas created)
NewReplicaSet: metabase-645b6d75bd (1/1 replicas created)
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal ScalingReplicaSet 55m deployment-controller Scaled up replica set metabase-7946cbc7bf to 1
Normal ScalingReplicaSet 50s deployment-controller Scaled down replica set metabase-645b6d75bd to 0
Normal ScalingReplicaSet 28s (x2 over 43m) deployment-controller Scaled up replica set metabase-645b6d75bd to 1
This is the yaml rendering for the deployment:
kubectl get deployment metabase -n metabase -oyaml
apiVersion: apps/v1
kind: Deployment
metadata:
annotations:
deployment.kubernetes.io/revision: "4"
meta.helm.sh/release-name: metabase
meta.helm.sh/release-namespace: metabase
creationTimestamp: "2022-02-15T11:52:14Z"
generation: 4
labels:
app: metabase
app.kubernetes.io/managed-by: Helm
chart: metabase-1.4.0
heritage: Helm
release: metabase
name: metabase
namespace: metabase
resourceVersion: "75149733"
uid: 50e3d7a3-56ec-4a09-9ba3-0b4f334fdb32
spec:
progressDeadlineSeconds: 600
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app: metabase
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
annotations:
checksum/config: ebbf78f5d3e95533542f724dd587556c25ab0764cea0cbeda62a482762698377
creationTimestamp: null
labels:
app: metabase
release: metabase
spec:
containers:
- env:
- name: MB_JETTY_HOST
value: 0.0.0.0
- name: MB_JETTY_PORT
value: "3000"
- name: MB_DB_TYPE
value: postgres
- name: MB_DB_CONNECTION_URI
valueFrom:
secretKeyRef:
key: connectionURI
name: metabase-secrets
- name: MB_PASSWORD_COMPLEXITY
value: normal
- name: MB_PASSWORD_LENGTH
value: "6"
- name: JAVA_TIMEZONE
value: UTC
- name: MB_EMOJI_IN_LOGS
value: "true"
- name: MB_COLORIZE_LOGS
value: "true"
image: metabase/metabase:v0.41.6
imagePullPolicy: IfNotPresent
livenessProbe:
failureThreshold: 6
httpGet:
path: /
port: 3000
scheme: HTTP
initialDelaySeconds: 120
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 30
name: metabase
ports:
- containerPort: 3000
protocol: TCP
readinessProbe:
failureThreshold: 3
httpGet:
path: /
port: 3000
scheme: HTTP
initialDelaySeconds: 30
periodSeconds: 5
successThreshold: 1
timeoutSeconds: 3
resources: {}
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
dnsPolicy: ClusterFirst
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
serviceAccount: default
serviceAccountName: default
terminationGracePeriodSeconds: 30
status:
availableReplicas: 1
conditions:
- lastTransitionTime: "2022-02-15T11:52:52Z"
lastUpdateTime: "2022-02-15T11:52:52Z"
message: Deployment has minimum availability.
reason: MinimumReplicasAvailable
status: "True"
type: Available
- lastTransitionTime: "2022-02-15T12:46:55Z"
lastUpdateTime: "2022-02-15T12:47:17Z"
message: ReplicaSet "metabase-645b6d75bd" is progressing.
reason: ReplicaSetUpdated
status: "True"
type: Progressing
observedGeneration: 4
readyReplicas: 1
replicas: 2
unavailableReplicas: 1
updatedReplicas: 1
It seems to be trying to use the postgres default port instead of the one specified in the URL:
The deployment seem correct, maybe metabase bug ? Then you should get help in https://github.com/metabase/metabase/issues
Hi @pmint93 - thank you for your work with this chart. It has been helpful. I need your help.
I want to switch to a postgres database.
I added a secret to my cluster with the connectionURI and referenced it in the helm chart, but it seems the deployment is not able to access the secret. I am not sure why that is.
my values
The error I am getting:
Please how do I fix this?