Gitea still complain about deprecated config even though I've already update them. Urgent! Please help! #481

Closed
opened 2023-08-01 09:42:25 +00:00 by nex · 4 comments

After upgrading Gitea on Kubernetes to Helm chart v9.1.0 with Docker tag 1.20.2, it failed to start:

2023/08/01 09:32:10 ...g/config_provider.go:321:deprecatedSetting() [E] Deprecated fallback `[mailer]` `MAILER_TYPE` present. Use `[mailer]` `PROTOCOL` instead. This fallback will be/has been removed in v1.19.0
2023/08/01 09:32:10 ...g/config_provider.go:321:deprecatedSetting() [E] Deprecated fallback `[mailer]` `HOST` present. Use `[mailer]` `SMTP_ADDR` instead. This fallback will be/has been removed in v1.19.0
2023/08/01 09:32:10 ...g/config_provider.go:321:deprecatedSetting() [E] Deprecated fallback `[mailer]` `IS_TLS_ENABLED` present. Use `[mailer]` `PROTOCOL` instead. This fallback will be/has been removed in v1.19.0
2023/08/01 09:32:10 ...es/setting/mailer.go:237:loadMailerFrom() [I] Mail Service Enabled
2023/08/01 09:32:10 ...les/setting/queue.go:99:func1() [E] Removed queue option: `[indexer].UPDATE_BUFFER_LEN`. Use new options in `[queue.issue_indexer]`
2023/08/01 09:32:10 ...les/setting/queue.go:111:loadQueueFrom() [F] Please update your app.ini to remove deprecated config options

Those deprecated config fields were in my old values.yaml but I've already updated them:

gitea:
    mailer:
      ENABLED: false
      FROM: gitea@internetapi.cn
      # SMTP family, if your provider does not explicitly say which protocol it uses but does provide a port, you can set SMTP_PORT instead and this will be inferred.
      # PROTOCOL: smtp+starttls
      SMTP_ADDR: mail.mydomain.com
      SMTP_PORT: 587
      USER: spoofer@mydomain.com

    indexer:
      REPO_INDEXER_ENABLED: false
      REPO_INDEXER_PATH: indexers/repos.bleve
      MAX_FILE_SIZE: 1048576

I've even mounted the data volume to a server and manually update the /data/gitea/conf/app.ini, I'm sure those deprecated config fields above don't exist in the config file nor in my deployment config anymore.

Seems like Gitea is still reading the old config from my database? (it says "Deprecated fallback", where's the fallback stored?) Or cache? How do I fix it? I cannot downgrade Gitea either since the DB is migrated. Please help! It's very urgent.

After upgrading Gitea on Kubernetes to Helm chart v9.1.0 with Docker tag 1.20.2, it failed to start: ``` 2023/08/01 09:32:10 ...g/config_provider.go:321:deprecatedSetting() [E] Deprecated fallback `[mailer]` `MAILER_TYPE` present. Use `[mailer]` `PROTOCOL` instead. This fallback will be/has been removed in v1.19.0 2023/08/01 09:32:10 ...g/config_provider.go:321:deprecatedSetting() [E] Deprecated fallback `[mailer]` `HOST` present. Use `[mailer]` `SMTP_ADDR` instead. This fallback will be/has been removed in v1.19.0 2023/08/01 09:32:10 ...g/config_provider.go:321:deprecatedSetting() [E] Deprecated fallback `[mailer]` `IS_TLS_ENABLED` present. Use `[mailer]` `PROTOCOL` instead. This fallback will be/has been removed in v1.19.0 2023/08/01 09:32:10 ...es/setting/mailer.go:237:loadMailerFrom() [I] Mail Service Enabled 2023/08/01 09:32:10 ...les/setting/queue.go:99:func1() [E] Removed queue option: `[indexer].UPDATE_BUFFER_LEN`. Use new options in `[queue.issue_indexer]` 2023/08/01 09:32:10 ...les/setting/queue.go:111:loadQueueFrom() [F] Please update your app.ini to remove deprecated config options ``` Those deprecated config fields were in my old `values.yaml` but I've already updated them: ```yaml gitea: mailer: ENABLED: false FROM: gitea@internetapi.cn # SMTP family, if your provider does not explicitly say which protocol it uses but does provide a port, you can set SMTP_PORT instead and this will be inferred. # PROTOCOL: smtp+starttls SMTP_ADDR: mail.mydomain.com SMTP_PORT: 587 USER: spoofer@mydomain.com indexer: REPO_INDEXER_ENABLED: false REPO_INDEXER_PATH: indexers/repos.bleve MAX_FILE_SIZE: 1048576 ``` I've even mounted the data volume to a server and manually update the `/data/gitea/conf/app.ini`, I'm sure those deprecated config fields above don't exist in the config file nor in my deployment config anymore. Seems like Gitea is still reading the old config from my database? (it says "Deprecated fallback", where's the fallback stored?) Or cache? How do I fix it? I cannot downgrade Gitea either since the DB is migrated. Please help! It's very urgent.
Member

There is only one place for your config which is app.ini. Due to #356 you need to remove the old config entries yourself, otherwise they will stay present in app.ini.

Seems like Gitea is still reading the old config from my database

They are not stored in the DB, only read from app.ini.

There is only one place for your config which is `app.ini`. Due to #356 you need to remove the old config entries yourself, otherwise they will stay present in `app.ini`. > Seems like Gitea is still reading the old config from my database They are not stored in the DB, only read from `app.ini`.
nex closed this issue 2023-08-01 09:54:02 +00:00
Member

Close without any final information?

Close without any final information?
Author

@pat-s Hi, it turned out the persistent volume name changed in the helm upgrade, so I found that there are two volumes, I had chagned app.ini in the old volume, which of course had no effect.

@pat-s Hi, it turned out the persistent volume name changed in the helm upgrade, so I found that there are two volumes, I had chagned `app.ini` in the old volume, which of course had no effect.
Member

Thanks. It's always nice to hear what caused the issue in the end instead of ghosting out without any information :)

Thanks. It's always nice to hear what caused the issue in the end instead of ghosting out without any information :)
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
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: gitea/helm-chart#481
No description provided.