My YunoHost server
Hardware: Computer (yunohost is running in a Virtual Machine)
YunoHost version: don’t know yet, but will start from debian stretch
I have access to my server : Through SSH, through the webadmin
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : except the VM aspect mention before, no
Description of my issue
Following a hardware failure, the server I’m running has lost all data (including the whole yunohost system), so I’m trying to figure out the proper step by step process to totally reinstall yunohost from a remote borg backup that I have.
I stumbled upon many parts of what has to be done in different parts of the forum, but I’m trying to have the whole process very clear, not to do mistake as I go, that would generate more problems.
Maybe some of this process is explained in yunohost documentation, but I don’t remember seeing all the steps, and also I can’t get to access the website at the moment.
So here is what I imagine I have to do:
Can anyone correct me, or add things, if I forgot some steps?
- Install debian stretch in the Virtual Machine
- Install yunohost the usual way
- Go through the postinstall process? — I’m wondering if I should do that because it will create the default user, setup a domain, but I want to reimport my previous configuration from the remote borg backup I have. Will the backup restoration replace what I’m doing at this step, and therefore I can put dummy domain and user names… ?
- Install borg_ynh app and manually set it up the way it was before — But from what I remember, this will generate an ssh key to connect to the remote server, but the remote server is expecting the previous key, that has been lost? — But if I don’t reinstall borg, how can I reimport backups from the remote server following the process described in this thread?.
- I guess at this point, I will have to connect to the remote backup server, and add the newly created ssh public key to it’s ssh config, so that the new server can connect to it.
- Now, I can run
borg export-tar BORG_USER@DOMAIN_OF_BACKUP_SERVER:backup::auto_conf_XXXX /home/yunohost.backup/archives/auto_conf_XXXX.tar.gz
in the new server to reimport the remote backup locally. - Then I can run
yunohost backup restore auto_conf_XXXX
which will restore the configurations (= users, domains…) - Now I can do the same process for data (
borg export-tar...
,yunohost backup restore...
) - Then I can restore each apps following the same process again — I don’t need to reinstall the apps before restoring them, right?
Maybe I’m making it more complicated than it is. It just bugs me this thing of having to first setup the server like new, install borg, to then be able to import backups. But I don’t really see another proper way I could do that.
The only other way I could imagine, would be to extract borg backups in the remote server, and then send them through ssh to the new yunohost, but it would mean decrypting the data in the remote server, which shouldn’t have to happen.
Any help, suggestions, and remarks are highly welcome in these uncomfortable times!!!