-
-
Notifications
You must be signed in to change notification settings - Fork 7.3k
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
Extend the backup.create action with password support #35520
base: next
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for home-assistant-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
📝 Walkthrough📝 WalkthroughWalkthroughThe documentation for the Backup integration has been updated to enhance clarity regarding the Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant BackupIntegration
participant BackupService
User->>BackupIntegration: Request to create backup
BackupIntegration->>BackupService: Create backup with optional parameters
alt If password is provided
BackupService->>BackupService: Encrypt backup with password
end
BackupService-->>BackupIntegration: Backup created
BackupIntegration-->>User: Backup creation confirmation
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 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: 0
🧹 Outside diff range and nitpick comments (2)
source/_integrations/backup.markdown (2)
40-43
: Enhance password parameter documentation with additional details.While the basic description is clear, security features benefit from comprehensive documentation. Consider adding:
- Password requirements or constraints (if any)
- Instructions for restoring password-protected backups
- Security considerations or best practices
Example enhancement:
password: - description: Encrypt the backup file with a password. + description: >- + Encrypt the backup file with a password. When restoring a password-protected backup, + you will need to provide this password. Store this password securely as there is + no way to recover the backup without it.
65-66
: LGTM! Good use of secrets for password storage.The example demonstrates secure password management using Home Assistant's secrets feature.
Consider adding a brief note about secrets:
data: password: !secret backup_password + # Store your backup password in secrets.yaml
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (1)
source/_integrations/backup.markdown
(2 hunks)
🔇 Additional comments (2)
source/_integrations/backup.markdown (2)
38-39
: LGTM! Clear documentation of parameter optionality.
The note clearly communicates that all parameters for the backup.create
action are optional, which is helpful for users.
Line range hint 93-108
: Update restore instructions for password-protected backups.
The "Restoring a backup" section should be updated to include information about handling password-protected backups for each installation type. This is especially important since we're adding password support.
For example, add password-related instructions:
2. If you use a {% term "Home Assistant Core" %} or {% term "Home Assistant Container" %} installation:
- A Home Assistant backup is just a tar file of the [configuration directory](/docs/configuration/#editing-configurationyaml), plus some metadata.
- To manually restore a backup, use the following command:
🧰 Tools
🪛 LanguageTool
[duplication] ~35-~35: Possible typo: you repeated a word
Context: ...up.create" %} The {% my developer_call_service service="backup.create" %} action can be used t...
(ENGLISH_WORD_REPEAT_RULE)
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
🧹 Outside diff range and nitpick comments (3)
source/_integrations/backup.markdown (3)
44-45
: Fix grammar in password descriptionAdd a comma for better readability.
description: >- - Encrypt the backup file with a password. When restoring a password-protected backup, you will need to provide this password. Store this password securely as there is no way to recover the backup without it. + Encrypt the backup file with a password. When restoring a password-protected backup, you will need to provide this password. Store this password securely, as there is no way to recover the backup without it.🧰 Tools
🪛 LanguageTool
[uncategorized] ~45-~45: Possible missing comma found.
Context: ...vide this password. Store this password securely as there is no way to recover the backu...(AI_HYDRA_LEO_MISSING_COMMA)
68-69
: Add explanatory comment to the exampleConsider adding a comment to emphasize security best practices.
data: + # Always use secrets.yaml for storing sensitive values like passwords password: !secret backup_password
Line range hint
89-91
: Document password handling during restorationThe restoration documentation should be updated to include instructions for password-protected backups, particularly for the manual restoration process using tar.
Consider adding:
- How to provide the password during restoration
- What happens if an incorrect password is provided
- Any specific considerations for different installation types
Would you like me to propose the additional documentation text?
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (1)
source/_integrations/backup.markdown
(3 hunks)
🧰 Additional context used
🪛 LanguageTool
source/_integrations/backup.markdown
[uncategorized] ~45-~45: Possible missing comma found.
Context: ...vide this password. Store this password securely as there is no way to recover the backu...
(AI_HYDRA_LEO_MISSING_COMMA)
🔇 Additional comments (1)
source/_integrations/backup.markdown (1)
22-23
: LGTM: Appropriate addition of secrets documentation link
Good addition of the secrets documentation link, which is relevant for securely storing backup passwords.
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.
Thank you, @ludeeus 👍
Proposed change
Documentation for feature added with home-assistant/core#110630
Type of change
current
branch).current
branch).next
branch).next
branch).Additional information
Checklist
current
branch.next
branch.Summary by CodeRabbit
New Features
backup.create
action are optional.password
parameter for encrypting backup files.Documentation