Skip to content

internal/config: make storage file paths overwritable via env vars#24177

Merged
rissson merged 1 commit into
goauthentik:mainfrom
alexeyabel:fix/make-storage-file-paths-overwritable-via-env-vars
Jul 20, 2026
Merged

internal/config: make storage file paths overwritable via env vars#24177
rissson merged 1 commit into
goauthentik:mainfrom
alexeyabel:fix/make-storage-file-paths-overwritable-via-env-vars

Conversation

@alexeyabel

Copy link
Copy Markdown
Contributor

Now *__FILE__PATH environemnt variables have an effect and can overwrite values from default.yml. Without this change uploaded files can not be accessed if the folder is different from the default /data because the GoLang part assumes a /data prefix and e.g. ignores AUTHENTIK_STORAGE__FILE__PATH.

How was this tested?

I have not tested this. I am on NixOS and make all does not work out-of-the-box due to dynamic linking. I presume that this minor change will not break anything.

Linked issues

I have not created an issue, since I already (hopefully) have the solution.

P.S. AFAICS your package list does not include Go modules. Therefore, I was not able to chose a fitting prefix and came up with config:. Feel free to change if you need. I just want this to be fixed.

@alexeyabel
alexeyabel requested a review from a team as a code owner July 18, 2026 21:07
@netlify

netlify Bot commented Jul 18, 2026

Copy link
Copy Markdown

Deploy Preview for authentik-docs ready!

Name Link
🔨 Latest commit 6365c59
🔍 Latest deploy log https://app.netlify.com/projects/authentik-docs/deploys/6a5c8b0d9f110a00088f7413
😎 Deploy Preview https://deploy-preview-24177--authentik-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov

codecov Bot commented Jul 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.07%. Comparing base (7418029) to head (6365c59).
⚠️ Report is 43 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #24177      +/-   ##
==========================================
+ Coverage   93.47%   94.07%   +0.59%     
==========================================
  Files        1059     1051       -8     
  Lines       63370    62946     -424     
  Branches      424        0     -424     
==========================================
- Hits        59235    59214      -21     
+ Misses       4135     3732     -403     
Flag Coverage Δ
conformance 35.26% <ø> (+<0.01%) ⬆️
e2e 40.26% <ø> (+<0.01%) ⬆️
integration 31.28% <ø> (-0.48%) ⬇️
rust ?
unit 92.66% <ø> (ø)
unit-migrate 92.67% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

Now *__FILE__PATH environemnt variables have an effect and can overwrite
values from default.yml. Without this change uploaded files can not be
accessed if the folder is different from the default /data because the
GoLang part assumes a /data prefix and e.g. ignores
AUTHENTIK_STORAGE__FILE__PATH.
@alexeyabel
alexeyabel force-pushed the fix/make-storage-file-paths-overwritable-via-env-vars branch from d9549fb to 6365c59 Compare July 19, 2026 08:30
@alexeyabel

Copy link
Copy Markdown
Contributor Author

@BeryJu I don't understand all these workflows and approval processes and thus how to proceed. Am I supposed to merge this myself or will any of the maintainers do it?

@rissson rissson changed the title config: make storage file paths overwritable via env vars internal/config: make storage file paths overwritable via env vars Jul 20, 2026
@rissson rissson self-assigned this Jul 20, 2026
@rissson rissson added area:backend backport/version-2026.5 Add this label to PRs to backport changes to version-2026.5 labels Jul 20, 2026
@github-project-automation github-project-automation Bot moved this from Todo to In Progress in authentik Core Jul 20, 2026
@rissson
rissson merged commit 84f89e0 into goauthentik:main Jul 20, 2026
118 of 119 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in authentik Core Jul 20, 2026
@rissson

rissson commented Jul 20, 2026

Copy link
Copy Markdown
Member

thank you for your contribution!

@authentik-cherry-pick

Copy link
Copy Markdown

🍒 Cherry-pick to version-2026.5 created: #24220

rissson pushed a commit that referenced this pull request Jul 20, 2026
…herry-pick #24177 to version-2026.5) (#24220)

Co-authored-by: Alexey Abel <17473656+alexeyabel@users.noreply.github.com>
Co-authored-by: Alexey Abel <dev@abelonline>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:backend backport/version-2026.5 Add this label to PRs to backport changes to version-2026.5

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants