-
Notifications
You must be signed in to change notification settings - Fork 687
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
added --preserve-tor-config flag to securedrop-admin restore #5115
added --preserve-tor-config flag to securedrop-admin restore #5115
Conversation
Thanks @zenmonkeykstop the diff looks good to me visually, but ran into some issues with (likely unrelated to this PR) with tailsconfig. Tested as follows, on prod VMs: On prod instance (VMs or hardware):
For the step:
Should we automate this step with ansible? It sounds like something a user would easily forget. |
Turns out the issues I described were because I copied the backed-up files to the wrong directory 🤦♂️ . The test plan was completed successfully 🎉 One last question before formally approving: |
This feature will support testing on the workstation side initially, and won't go out with the next point release. I'm inclined to leave it undocumented for now and fix the tor config handling for 1.3.0, because I don't want to make the existing backup documentation more complex and dissuade people from using it. But if you disagree, I'm not fundamentally opposed. |
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.
Since this operation is not destructive, and the help message seems sufficiently clear, I think that's fair. Thanks @zenmonkeykstop
Status
Ready for review
Description of Changes
Fixes #5107
Adds a
--preserve-tor-config
flag to thesecuredrop-admin restore
command, that, if set, will restore a backup tarball without overwriting the server's existing Tor configurations. This will allow a dataset from an SD instance to be applied and available on another instance at a different onion address.Sets flake8 max-line-length to 100, in line with standard for application code.
Testing
On prod instance (VMs or hardware):
./securedrop-admin backup
files from the
install_files/ansible-base` directory to ~/Persistent/sudo service tor reload
to load the new service config.files from ~/Persistent/ to the
install_files/ansible-base` directory, and run:Deployment
(deployed when workstation copies of the repo are updated)
Checklist
If you made changes to
securedrop-admin
:make -C admin test
) pass in the admin development containerIf you made non-trivial code changes: