mastodon_ynh
mastodon_ynh copied to clipboard
Upgrading wipe the edits on .env.production
Describe the bug
After performing an update from YNH web panel, the .env.production
file is back to the version installed by the app, without the S3 credentials I entered. Which cause the app to not being able to access the previously stored objects and having dead link all over the app.
Context
- YunoHost version: 11.2.3
- I have access to my server: Through SSH & through the webadmin
- Are you in a special context or did you perform some particular tweaking on your YunoHost instance?: no
- If upgrading, current package version: 4.1.4~ynh1
Steps to reproduce
- Prior to an update, edit the
.env.production
file - Perform update
- Re-open the
.env.production
file
Expected behavior
File still contains edits
Hi. This is a know issue/missing feature for this package (duplicate #385).
We are trying to create config_panel.toml
that will address this issue.
Could you precise which keys you would want to persist in the .env.production
?
Are you proxying object storage through nginx ? (https://docs.joinmastodon.org/admin/optional/object-storage-proxy/)
Essentially I would need:
-
S3_ENABLED
(=true) -
S3_BUCKET
-
AWS_ACCESS_KEY_ID
-
AWS_SECRET_ACCESS_KEY
-
S3_REGION
I'm not using the other S3 settings, defaults values works just fine.
Not using proxying object storage since I'm the only one on my instance, so I don't experience any "rush" of access when a new post is made. That would mitigate temporary disruption of S3 connexion though. I'll consider it as an additional step to put in place, thanks for sharing.
Sorry for hijacking this issue, but some other settings could/should also be made available (I was planning on trying this myself but lack of documentation of configpanel meant it went nowhere):
LDAP_ENABLED (=false for public instances)
DEEPL_API_KEY=(INSERT API KEY) DEEPL_PLAN (=free)
For allowing machine translation.
Thanks!
OH YEAH, the DEEPL_API_KEY and DEEPL_PLAN too ❤
Hi, I might be late to the party, but I wanted to add another set of settings: Since Mastodon has full text search it would be nice to store the elasticsearch values too:
ES_ENABLED=true
ES_HOST=localhost
ES_PORT=9200
ES_PRESET=