Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add access to share for use with other add-ons #397

Merged
merged 2 commits into from
May 14, 2024

Conversation

sikaiser
Copy link
Contributor

Proposed Changes

Add acces to the directories /media and /share, as originally requested in #133. According to this post in the community forum, these folders are intended for the sharing of files between (home assistant and) addons, so I think the addon should have access to them.

All 3 of /media, /ssl and /share were designed in part to be a place shared between Home Assistant and Addons so multiple things could read and write to it and potentially communicate with each other. /share was kind of the bucket for files which didn’t fit the obvious types of the other two (media in /media, ssl-related files in /ssl, everything else in /share).

The specific use case that brought me to this: I have an SQLite database file that I want to store locally and read in Grafana. I could put it in /homeassistant_config or /ssl, but conceptually it doesn't fit there. I'd much prefer having it in /share.

Related Issues

Originally discussed in #133.

@frenck
Copy link
Member

frenck commented Apr 24, 2024

And why /media?

@sikaiser
Copy link
Contributor Author

I thought to include it because it is also intended for access across addons. But I personally can not give you a concrete use case. /share solves my specific problem.

@frenck
Copy link
Member

frenck commented Apr 24, 2024

Right, but just adding it because we "can" is not something I'm a fan of. Everything we add adds more access to the add-on. Especially without a direct need or use-case for it, that is just unnecessary.

Let's remove media.

@sikaiser
Copy link
Contributor Author

My suggestion to add it was because in my understanding it is intended for shared access, not because we "can". But I see your point and having access to /share alone is great too. I've updated the pull request.

@frenck frenck added enhancement Enhancement of the code, not introducing new features. labels May 14, 2024
Copy link
Member

@frenck frenck left a comment

Choose a reason for hiding this comment

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

Thanks, @sikaiser 👍

../Frenck

@frenck frenck changed the title Add access to /media and /share directories so that data can be read from local storage and exchanged with other addons Add access to share for use with other addons May 14, 2024
@frenck frenck changed the title Add access to share for use with other addons Add access to share for use with other add-ons May 14, 2024
@frenck frenck merged commit 26e6b6e into hassio-addons:main May 14, 2024
12 of 13 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators May 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Enhancement of the code, not introducing new features.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants