[BUG] Upgrade to > 2.0.0 deleted PVC together with all data
Describe the bug When upgrading the helm-chart from 1.x to 2.x my whole setup is being deleted including the PVC, which subsequently deletes all my data and e-mails.
Subsequently having a fresh install, I can't access the admin because of "Internal Server Error"
helm_v3 install --namespace mailu-v2 --version 2.1.1 mailu-v2 mailu-v2/mailu --values /config/values-01_HelmChart.yaml
Environment
- K3s
Additional context
mariadb:
enabled: false
postgresql:
enabled: false
domain: example.com
hostnames:
- mail.example.com
admin:
extraEnvVars:
- name: LD_PRELOAD
value: /usr/lib/libhardened_malloc.so
- name: DEBUG
value: "true"
ingress:
annotations:
cert-manager.io/cluster-issuer: letsencrypt-production
nginx.ingress.kubernetes.io/proxy-body-size: "0"
traefik.ingress.kubernetes.io/router.middlewares: default-redirect-https@kubernetescrd
className: ""
enabled: true
realIpFrom: 0.0.0.0/0
realIpHeader: X-Forwarded-For
initialAccount:
domain: example.com
password: chang3m3!
username: mailadmin
persistence:
accessMode: ReadWriteOnce
single_pvc: true
size: 11Gi
postmaster: postmaster
webmail:
enabled: false
secretKey: blablabla
front:
hostPort:
enabled: false
externalService:
enabled: True
type: LoadBalancer
ports:
pop3: false
pop3s: true
imap: false
imaps: true
smtp: true
smtps: true
submission: true
@NotANormalNerd I had the same issue with admin access, here's how I fixed it (assuming you are using Traefik like me):
- Turn off the
ingressinvalues.yaml(setenabled: false), it used to point to port80onmailu-front, but now points to port443, which causes Traefik to throw an error 500 because the backend certificate is not valid for the domain[service].[namespace].svc.[cluster-domain] - Create a servers transport for
mailu-front(make sure your cluster domain iscluster.localor change it inserverNamebelow to match).apiVersion: traefik.io/v1alpha1 kind: ServersTransport metadata: name: mailu-web spec: serverName: mailu-front.[namespace].svc.cluster.local insecureSkipVerify: true # <-- This fixes the issue - Create manually an ingress (and certificate if needed), but change the
servicesto use the new servers transport.services: - name: mailu-front serversTransport: mailu-web port: 443
The removal of the PVC is documented behaviour in https://github.com/Mailu/helm-charts/blob/master/mailu/MIGRATION_GUIDE.md
@WebSpider This migration guide applies for migrating to 1.0.0
If this also applies to 2.0.0 then at least the documentation should be updated.
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.
This issue was closed because it has been stalled for 5 days with no activity.
@NotANormalNerd thank you for reporting this, could you tell me exactly from which version you were upgrading and to which one?
How did you perform the upgrade?
This should not happen indeed but there were no changes to the pvc when using single_pvc since 1.0.0-beta.23.
https://github.com/Mailu/helm-charts/commit/d00d768f2b82fae5c142d6b92fff0f475e4c566a
The last 1.5 version of the Chart to the 2.0 and even the 2.1 version of the Chart.
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.
This issue was closed because it has been stalled for 5 days with no activity.