[GH-ISSUE #1552] 💬 [Question] After restart or Docker update, settings are gone #682

Closed
opened 2026-02-25 21:35:40 +03:00 by kerem · 9 comments
Owner

Originally created by @ghost on GitHub (Jun 17, 2025).
Original GitHub issue: https://github.com/cypht-org/cypht/issues/1552

Originally assigned to: @IrAlfred on GitHub.

Hi, first of all: awesome project, exactly what I was looking for.
Unfortunately, when Docker is restarted or the image is updated, the settings are gone — especially the added IMAP & SMTP accounts are lost.

Is there something that needs to be configured to make them persist?
I also performed the save operation, but unfortunately it didn’t help.

Originally created by @ghost on GitHub (Jun 17, 2025). Original GitHub issue: https://github.com/cypht-org/cypht/issues/1552 Originally assigned to: @IrAlfred on GitHub. Hi, first of all: awesome project, exactly what I was looking for. Unfortunately, when Docker is restarted or the image is updated, the settings are gone — especially the added IMAP & SMTP accounts are lost. Is there something that needs to be configured to make them persist? I also performed the save operation, but unfortunately it didn’t help.
kerem 2026-02-25 21:35:40 +03:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@ljcbaby commented on GitHub (Jun 17, 2025):

your USER_CONFIG_TYPE is ?

<!-- gh-comment-id:2980979803 --> @ljcbaby commented on GitHub (Jun 17, 2025): your `USER_CONFIG_TYPE` is ?
Author
Owner

@ghost commented on GitHub (Jun 17, 2025):

USER_CONFIG_TYPE=file

But use a MariaDB 10 database.

<!-- gh-comment-id:2980994580 --> @ghost commented on GitHub (Jun 17, 2025): USER_CONFIG_TYPE=file But use a MariaDB 10 database.
Author
Owner

@ghost commented on GitHub (Jun 17, 2025):

ADMIN_USERS=


ALLOW_EXTERNAL_IMAGE_SOURCES=true
ALLOW_LONG_SESSION=false

ALWAYS_MOBILE_UI=false

APP_2FA_SECRET=************************
APP_2FA_SIMPLE=true
APP_NAME=Cypht

ATTACHMENT_DIR=/var/lib/hm3/attachments

AUTH_CLASS=
AUTH_TYPE=DB

AUTO_CREATE_PROFILE=false

CARD_DAV_SERVER=http://localhost:5232

COOKIE_DOMAIN=
COOKIE_PATH=

CSS_COMPRESS=false

CYPHT_MODULES=core,2fa,imap,smtp,account,idle_timer,themes,nux,developer,history,saved_searches,advanced_search,highlights,profiles,inline_message,imap_folders,keyboard_shortcuts

DB_CONNECTION_TYPE=host
DB_DRIVER=mysql
DB_HOST=192.168.1.11
DB_NAME=*******************
DB_PASS=*********************
DB_PORT=3306
DB_SOCKET=/var/lib/mysqld/mysqld.sock
DB_USER=*******************

DEBUG_LOG=false

DEFAULT_EMAIL_DOMAIN=
DEFAULT_LANGUAGE=de
DEFAULT_SETTING_ALL_EMAIL_PER_SOURCE=20
DEFAULT_SETTING_ALL_EMAIL_SINCE=-1 week
DEFAULT_SETTING_ALL_PER_SOURCE=20
DEFAULT_SETTING_ALL_SINCE=-1 week
DEFAULT_SETTING_DISABLE_DELETE_PROMPT=false
DEFAULT_SETTING_DRAFT_PER_SOURCE=20
DEFAULT_SETTING_DRAFT_SINCE=-1 week
DEFAULT_SETTING_ENABLE_KEYBOARD_SHORTCUTS=false
DEFAULT_SETTING_ENABLE_SIEVE_FILTER=false
DEFAULT_SETTING_FEED_LIMIT=20
DEFAULT_SETTING_FEED_SINCE=-1 week
DEFAULT_SETTING_FLAGGED_PER_SOURCE=20
DEFAULT_SETTING_FLAGGED_SINCE=-1 week
DEFAULT_SETTING_GITHUB_LIMIT=20
DEFAULT_SETTING_GITHUB_SINCE=-1 week
DEFAULT_SETTING_IMAP_PER_PAGE=20
DEFAULT_SETTING_INLINE_MESSAGE=false
DEFAULT_SETTING_INLINE_MESSAGE_STYLE=right
DEFAULT_SETTING_JUNK_PER_SOURCE=20
DEFAULT_SETTING_JUNK_SINCE=-1 week
DEFAULT_SETTING_LANGUAGE=de
DEFAULT_SETTING_LIST_STYLE=email_style
DEFAULT_SETTING_MSG_PART_ICONS=true
DEFAULT_SETTING_NO_FOLDER_ICONS=false
DEFAULT_SETTING_NO_PASSWORD_SAVE=false
DEFAULT_SETTING_PAGINATE_LINKS=true
DEFAULT_SETTING_REVIEW_SENT_EMAIL=true
DEFAULT_SETTING_SEARCH_SINCE=-1 week
DEFAULT_SETTING_SENT_PER_SOURCE=20
DEFAULT_SETTING_SENT_SINCE=-1 week
DEFAULT_SETTING_SHOW_LIST_ICONS=true
DEFAULT_SETTING_SIMPLE_MSG_PARTS=false
DEFAULT_SETTING_SMTP_AUTO_BCC=false
DEFAULT_SETTING_SMTP_COMPOSE_TYPE=
DEFAULT_SETTING_SNOOZED_PER_SOURCE=20
DEFAULT_SETTING_SNOOZED_SINCE=-1 week
DEFAULT_SETTING_START_PAGE=none
DEFAULT_SETTING_TAGS_PER_SOURCE=20
DEFAULT_SETTING_TAGS_SINCE=-1 week
DEFAULT_SETTING_TEXT_ONLY=false
DEFAULT_SETTING_THEME=darkly
DEFAULT_SETTING_TIMEZONE=europe/berlin
DEFAULT_SETTING_TRASH_PER_SOURCE=20
DEFAULT_SETTING_TRASH_SINCE=-1 week
DEFAULT_SETTING_UNREAD_EXCLUDE_FEEDS=false
DEFAULT_SETTING_UNREAD_EXCLUDE_GITHUB=false
DEFAULT_SETTING_UNREAD_EXCLUDE_WORDPRESS=false
DEFAULT_SETTING_UNREAD_PER_SOURCE=20
DEFAULT_SETTING_UNREAD_SINCE=-1 week
DEFAULT_SETTING_WORDPRESS_SINCE=-1 week

DEFAULT_SMTP_NAME=
DEFAULT_SMTP_NO_AUTH=false
DEFAULT_SMTP_PORT=
DEFAULT_SMTP_SERVER=
DEFAULT_SMTP_TLS=false

DISABLE_EMPTY_SUPERGLOBALS=false
DISABLE_FINGERPRINT=false
DISABLE_INI_SETTINGS=false
DISABLE_IP_CHECK=false
DISABLE_OPEN_BASE_DIR=false
DISABLE_ORIGIN_CHECK=false

DYNAMIC_HOST=true
DYNAMIC_HOST_SUBDOMAIN=false
DYNAMIC_MAIL_SUBDOMAIN=false
DYNAMIC_SMTP_SUBDOMAIN=false
DYNAMIC_USER=false

ENABLE_MEMCACHED=true
ENABLE_REDIS=true

ENCRYPT_AJAX_REQUESTS=false
ENCRYPT_LOCAL_STORAGE=false

FANCY_LOGIN=true

GITHUB_AUTH_URL=https://github.com/login/oauth/authorize
GITHUB_CLIENT_ID=false
GITHUB_CLIENT_SECRET=
GITHUB_REDIRECT_URI=http://localhost/?page=home
GITHUB_TOKEN_URL=https://github.com/login/oauth/access_token

GMAIL_AUTH_URI=https://accounts.google.com/o/oauth2/auth
GMAIL_CLIENT_ID=
GMAIL_CLIENT_SECRET=
GMAIL_CLIENT_URI=http://localhost/?page=home
GMAIL_REFRESH_URI=https://www.googleapis.com/oauth2/v3/token
GMAIL_TOKEN_URI=https://www.googleapis.com/oauth2/v3/token

IMAP_AUTH_NAME=Gandi
IMAP_AUTH_PORT=993
IMAP_AUTH_SERVER=mail.gandi.net
IMAP_AUTH_SIEVE_CONF_HOST=false
IMAP_AUTH_SIEVE_TLS_MODE=true
IMAP_AUTH_TLS=true

JS_COMPRESS=false
JS_EXCLUDE_DEPS=false


LONG_SESSION_LIFETIME=30

MEMCACHED_AUTH=false
MEMCACHED_PASS=
MEMCACHED_PORT=11211
MEMCACHED_SERVER=127.0.0.1
MEMCACHED_USER=

OFFICE365_AUTH_URI=https://login.live.com/oauth20_authorize.srf
OFFICE365_CLIENT_ID=
OFFICE365_CLIENT_SECRET=
OFFICE365_CLIENT_URI=http://localhost/?page=home
OFFICE365_REFRESH_URI=https://login.live.com/oauth20_token.srf
OFFICE365_TOKEN_URI=https://login.live.com/oauth20_token.srf

OUTLOOK_AUTH_URI=https://login.live.com/oauth20_authorize.srf
OUTLOOK_CLIENT_ID=
OUTLOOK_CLIENT_SECRET=
OUTLOOK_CLIENT_URI=http://localhost/?page=home
OUTLOOK_REFRESH_URI=https://login.live.com/oauth20_token.srf
OUTLOOK_TOKEN_URI=https://login.live.com/oauth20_token.srf

RECAPTCHA_SECRET=
RECAPTCHA_SITE_KEY=

REDIRECT_AFTER_LOGIN=

REDIS_INDEX=1
REDIS_PASS=
REDIS_PORT=6379
REDIS_SERVER=127.0.0.1
REDIS_SOCKET=/var/run/redis/redis-server.sock

SESSION_CLASS=
SESSION_TYPE=PHP

SINGLE_SERVER_MODE=true

USER_CONFIG_TYPE=file
USER_SETTINGS_DIR=/var/lib/hm3/users
<!-- gh-comment-id:2981005642 --> @ghost commented on GitHub (Jun 17, 2025): ```dockerfile ADMIN_USERS= ALLOW_EXTERNAL_IMAGE_SOURCES=true ALLOW_LONG_SESSION=false ALWAYS_MOBILE_UI=false APP_2FA_SECRET=************************ APP_2FA_SIMPLE=true APP_NAME=Cypht ATTACHMENT_DIR=/var/lib/hm3/attachments AUTH_CLASS= AUTH_TYPE=DB AUTO_CREATE_PROFILE=false CARD_DAV_SERVER=http://localhost:5232 COOKIE_DOMAIN= COOKIE_PATH= CSS_COMPRESS=false CYPHT_MODULES=core,2fa,imap,smtp,account,idle_timer,themes,nux,developer,history,saved_searches,advanced_search,highlights,profiles,inline_message,imap_folders,keyboard_shortcuts DB_CONNECTION_TYPE=host DB_DRIVER=mysql DB_HOST=192.168.1.11 DB_NAME=******************* DB_PASS=********************* DB_PORT=3306 DB_SOCKET=/var/lib/mysqld/mysqld.sock DB_USER=******************* DEBUG_LOG=false DEFAULT_EMAIL_DOMAIN= DEFAULT_LANGUAGE=de DEFAULT_SETTING_ALL_EMAIL_PER_SOURCE=20 DEFAULT_SETTING_ALL_EMAIL_SINCE=-1 week DEFAULT_SETTING_ALL_PER_SOURCE=20 DEFAULT_SETTING_ALL_SINCE=-1 week DEFAULT_SETTING_DISABLE_DELETE_PROMPT=false DEFAULT_SETTING_DRAFT_PER_SOURCE=20 DEFAULT_SETTING_DRAFT_SINCE=-1 week DEFAULT_SETTING_ENABLE_KEYBOARD_SHORTCUTS=false DEFAULT_SETTING_ENABLE_SIEVE_FILTER=false DEFAULT_SETTING_FEED_LIMIT=20 DEFAULT_SETTING_FEED_SINCE=-1 week DEFAULT_SETTING_FLAGGED_PER_SOURCE=20 DEFAULT_SETTING_FLAGGED_SINCE=-1 week DEFAULT_SETTING_GITHUB_LIMIT=20 DEFAULT_SETTING_GITHUB_SINCE=-1 week DEFAULT_SETTING_IMAP_PER_PAGE=20 DEFAULT_SETTING_INLINE_MESSAGE=false DEFAULT_SETTING_INLINE_MESSAGE_STYLE=right DEFAULT_SETTING_JUNK_PER_SOURCE=20 DEFAULT_SETTING_JUNK_SINCE=-1 week DEFAULT_SETTING_LANGUAGE=de DEFAULT_SETTING_LIST_STYLE=email_style DEFAULT_SETTING_MSG_PART_ICONS=true DEFAULT_SETTING_NO_FOLDER_ICONS=false DEFAULT_SETTING_NO_PASSWORD_SAVE=false DEFAULT_SETTING_PAGINATE_LINKS=true DEFAULT_SETTING_REVIEW_SENT_EMAIL=true DEFAULT_SETTING_SEARCH_SINCE=-1 week DEFAULT_SETTING_SENT_PER_SOURCE=20 DEFAULT_SETTING_SENT_SINCE=-1 week DEFAULT_SETTING_SHOW_LIST_ICONS=true DEFAULT_SETTING_SIMPLE_MSG_PARTS=false DEFAULT_SETTING_SMTP_AUTO_BCC=false DEFAULT_SETTING_SMTP_COMPOSE_TYPE= DEFAULT_SETTING_SNOOZED_PER_SOURCE=20 DEFAULT_SETTING_SNOOZED_SINCE=-1 week DEFAULT_SETTING_START_PAGE=none DEFAULT_SETTING_TAGS_PER_SOURCE=20 DEFAULT_SETTING_TAGS_SINCE=-1 week DEFAULT_SETTING_TEXT_ONLY=false DEFAULT_SETTING_THEME=darkly DEFAULT_SETTING_TIMEZONE=europe/berlin DEFAULT_SETTING_TRASH_PER_SOURCE=20 DEFAULT_SETTING_TRASH_SINCE=-1 week DEFAULT_SETTING_UNREAD_EXCLUDE_FEEDS=false DEFAULT_SETTING_UNREAD_EXCLUDE_GITHUB=false DEFAULT_SETTING_UNREAD_EXCLUDE_WORDPRESS=false DEFAULT_SETTING_UNREAD_PER_SOURCE=20 DEFAULT_SETTING_UNREAD_SINCE=-1 week DEFAULT_SETTING_WORDPRESS_SINCE=-1 week DEFAULT_SMTP_NAME= DEFAULT_SMTP_NO_AUTH=false DEFAULT_SMTP_PORT= DEFAULT_SMTP_SERVER= DEFAULT_SMTP_TLS=false DISABLE_EMPTY_SUPERGLOBALS=false DISABLE_FINGERPRINT=false DISABLE_INI_SETTINGS=false DISABLE_IP_CHECK=false DISABLE_OPEN_BASE_DIR=false DISABLE_ORIGIN_CHECK=false DYNAMIC_HOST=true DYNAMIC_HOST_SUBDOMAIN=false DYNAMIC_MAIL_SUBDOMAIN=false DYNAMIC_SMTP_SUBDOMAIN=false DYNAMIC_USER=false ENABLE_MEMCACHED=true ENABLE_REDIS=true ENCRYPT_AJAX_REQUESTS=false ENCRYPT_LOCAL_STORAGE=false FANCY_LOGIN=true GITHUB_AUTH_URL=https://github.com/login/oauth/authorize GITHUB_CLIENT_ID=false GITHUB_CLIENT_SECRET= GITHUB_REDIRECT_URI=http://localhost/?page=home GITHUB_TOKEN_URL=https://github.com/login/oauth/access_token GMAIL_AUTH_URI=https://accounts.google.com/o/oauth2/auth GMAIL_CLIENT_ID= GMAIL_CLIENT_SECRET= GMAIL_CLIENT_URI=http://localhost/?page=home GMAIL_REFRESH_URI=https://www.googleapis.com/oauth2/v3/token GMAIL_TOKEN_URI=https://www.googleapis.com/oauth2/v3/token IMAP_AUTH_NAME=Gandi IMAP_AUTH_PORT=993 IMAP_AUTH_SERVER=mail.gandi.net IMAP_AUTH_SIEVE_CONF_HOST=false IMAP_AUTH_SIEVE_TLS_MODE=true IMAP_AUTH_TLS=true JS_COMPRESS=false JS_EXCLUDE_DEPS=false LONG_SESSION_LIFETIME=30 MEMCACHED_AUTH=false MEMCACHED_PASS= MEMCACHED_PORT=11211 MEMCACHED_SERVER=127.0.0.1 MEMCACHED_USER= OFFICE365_AUTH_URI=https://login.live.com/oauth20_authorize.srf OFFICE365_CLIENT_ID= OFFICE365_CLIENT_SECRET= OFFICE365_CLIENT_URI=http://localhost/?page=home OFFICE365_REFRESH_URI=https://login.live.com/oauth20_token.srf OFFICE365_TOKEN_URI=https://login.live.com/oauth20_token.srf OUTLOOK_AUTH_URI=https://login.live.com/oauth20_authorize.srf OUTLOOK_CLIENT_ID= OUTLOOK_CLIENT_SECRET= OUTLOOK_CLIENT_URI=http://localhost/?page=home OUTLOOK_REFRESH_URI=https://login.live.com/oauth20_token.srf OUTLOOK_TOKEN_URI=https://login.live.com/oauth20_token.srf RECAPTCHA_SECRET= RECAPTCHA_SITE_KEY= REDIRECT_AFTER_LOGIN= REDIS_INDEX=1 REDIS_PASS= REDIS_PORT=6379 REDIS_SERVER=127.0.0.1 REDIS_SOCKET=/var/run/redis/redis-server.sock SESSION_CLASS= SESSION_TYPE=PHP SINGLE_SERVER_MODE=true USER_CONFIG_TYPE=file USER_SETTINGS_DIR=/var/lib/hm3/users ```
Author
Owner

@ljcbaby commented on GitHub (Jun 18, 2025):

Is /var/lib/hm3/users persist?

<!-- gh-comment-id:2983797567 --> @ljcbaby commented on GitHub (Jun 18, 2025): Is `/var/lib/hm3/users` persist?
Author
Owner

@IrAlfred commented on GitHub (Jul 3, 2025):

@SvensenDE You need to persist the /var/lib/hm3/users directory using a volume if you want to keep your settings after restarting or updating the Docker container.

Let us know the result of your testing or if you need further assistance!

<!-- gh-comment-id:3033933397 --> @IrAlfred commented on GitHub (Jul 3, 2025): @SvensenDE You need to persist the /var/lib/hm3/users directory using a volume if you want to keep your settings after restarting or updating the Docker container. Let us know the result of your testing or if you need further assistance!
Author
Owner

@marclaporte commented on GitHub (Aug 20, 2025):

You need to persist the /var/lib/hm3/users directory using a volume if you want to keep your settings after restarting or updating the Docker container.

@IrAlfred Is this indicated in the documentation?

<!-- gh-comment-id:3206181125 --> @marclaporte commented on GitHub (Aug 20, 2025): > You need to persist the /var/lib/hm3/users directory using a volume if you want to keep your settings after restarting or updating the Docker container. @IrAlfred Is this indicated in the documentation?
Author
Owner

@IrAlfred commented on GitHub (Aug 20, 2025):

@IrAlfred Is this indicated in the documentation?

It's not documented, I will add more details about docker setup

<!-- gh-comment-id:3206296533 --> @IrAlfred commented on GitHub (Aug 20, 2025): > [@IrAlfred](https://github.com/IrAlfred) Is this indicated in the documentation? It's not documented, I will add more details about docker setup
Author
Owner

@IrAlfred commented on GitHub (Aug 23, 2025):

Hello @ghost

In case you are still struggling with your setup, here is what you need.

Update your cypht service in the docker-compose.yml file to include the volumes section:

cypht:
    image: cypht/cypht:2.4.0
    ports:
        - "80:80"
    environment:
        - AUTH_USERNAME=admin
        # ... other environment variables
    volumes:
        # Mount host directories for persistent storage
        - ./data/user_settings:/var/lib/hm3/users          # User profiles and settings
        - ./data/user_attachments:/var/lib/hm3/attachments # Email attachments
<!-- gh-comment-id:3216915973 --> @IrAlfred commented on GitHub (Aug 23, 2025): Hello @ghost In case you are still struggling with your setup, here is what you need. Update your cypht service in the docker-compose.yml file to include the volumes section: ``` cypht: image: cypht/cypht:2.4.0 ports: - "80:80" environment: - AUTH_USERNAME=admin # ... other environment variables volumes: # Mount host directories for persistent storage - ./data/user_settings:/var/lib/hm3/users # User profiles and settings - ./data/user_attachments:/var/lib/hm3/attachments # Email attachments ```
Author
Owner

@IrAlfred commented on GitHub (Aug 24, 2025):

We are closing this issue due to inactivity. If you are still experiencing this problem, please feel free to reopen it or comment with additional details, and we will be happy to investigate further.

<!-- gh-comment-id:3218358453 --> @IrAlfred commented on GitHub (Aug 24, 2025): We are closing this issue due to inactivity. If you are still experiencing this problem, please feel free to reopen it or comment with additional details, and we will be happy to investigate further.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/cypht#682
No description provided.