-
-
Notifications
You must be signed in to change notification settings - Fork 21
Migrate add-on data out of Home Assitant config dir #556
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
base: main
Are you sure you want to change the base?
Conversation
WalkthroughThe changes update the configuration mapping by renaming an entry and adding a new one to support configuration migration. Additionally, a new migration routine in the startup script checks for legacy configuration files and, when needed, moves them from the Home Assistant directory to the add-on configuration directory with error handling. These modifications ensure that configuration files are updated and migrated without altering the existing core functionality. Changes
Sequence Diagram(s)sequenceDiagram
participant S as Startup Script
participant HA as Home Assistant Config
participant ADDON as Addon Config
S->>HA: Check for /homeassistant/glances/glances.conf
S->>ADDON: Check if /config/glances.conf exists
alt Legacy config exists and no target file
S->>HA: Enable dotglob and move files from HA to ADDON
ADDON-->>S: Migration successful
else
S-->>S: Skip migration
end
Assessment against linked issues
Poem
Tip ⚡🧪 Multi-step agentic review comment chat (experimental)
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
glances/config.yaml (1)
25-29
: Mapping Updates for Configuration MigrationYou've updated the mapping by replacing the previous
config:rw
withaddon_config:rw
and added a new entryhomeassistant_config:rw # to enable migration to addon_config
. This clearly indicates the new structure and supports the migration process.
Please ensure that the mount points specified here match the filesystem paths used later in the migration script.
There hasn't been any activity on this pull request recently. This pull request has been automatically marked as stale because of that and will be closed if no further activity occurs within 7 days. Thank you for your contributions. |
@frenck what about integrating this one? Also commenting to prevent it from getting stale. |
Proposed Changes
This PR adds support for addon config to Glances, and migrates the config out of Home Assistant config dir into the addon config dir.
Related Issues
Closes #543
Refs home-assistant/supervisor#4650
Summary by CodeRabbit