Skip to content

Adjust instructions for K3s Storage Configuration#1206

Open
Zaustie wants to merge 2 commits intoelement-hq:mainfrom
Zaustie:patch-1
Open

Adjust instructions for K3s Storage Configuration#1206
Zaustie wants to merge 2 commits intoelement-hq:mainfrom
Zaustie:patch-1

Conversation

@Zaustie
Copy link
Copy Markdown

@Zaustie Zaustie commented Mar 31, 2026

The K3s storage path can be adjusted easily by setting the K3S_DATA_DIR environment variable before installing K3s.

As a sidenote this should correspond to the DATADIR variable mentioned in the synapse configuration option for media_store_path and related options.

@Zaustie Zaustie requested a review from a team as a code owner March 31, 2026 10:39
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Mar 31, 2026

CLA assistant check
All committers have signed the CLA.

Copy link
Copy Markdown
Member

@benbz benbz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for raising.

As I understand it, K3S_DATA_DIR impacts all k3s state and not just the local path provisioner storage.

I'm happy for this to change however

  • It should remain in the same place in the advanced docs
  • It should mention the default location of /var/lib/rancher/k3s

@Zaustie
Copy link
Copy Markdown
Author

Zaustie commented Apr 2, 2026

Oh yeah that is a good point, I'll just add it as an alternative to the original section in the advanced part of the instructions. I've also added the implementation I've actually ended up using by mounting my drive to /var during OS installation.

K3s by default deploys the storage in `/var/lib/rancher/k3s/storage/`. If you want to change the path, you will have to run the K3s setup with the parameter `--default-local-storage-path <your path>`.


If you do not mind modifying the you storage path for the entirey of K3s you can also adjust the `K3S_DATA_DIR` environment variable before installing K3s using
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
If you do not mind modifying the you storage path for the entirey of K3s you can also adjust the `K3S_DATA_DIR` environment variable before installing K3s using
If you do not mind modifying the you storage path for the entirety of K3s you can also adjust the `K3S_DATA_DIR` environment variable before installing K3s using

@benbz
Copy link
Copy Markdown
Member

benbz commented Apr 2, 2026

I'm happy for this to go out without a changelog entry, but if you'd like it mentioned then newsfragment/1206.doc.md needs to be added to this PR with a sentence describing the changes

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 2, 2026

dyff of changes in rendered templates of CI manifests

No changes in rendered templates

@Zaustie
Copy link
Copy Markdown
Author

Zaustie commented Apr 2, 2026

I'm fine with it either way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants