diff --git a/README.md b/README.md index f88752d..e1b17b6 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Borg for Yunohost +# Borg Backup for Yunohost [![Latest Version](https://img.shields.io/badge/version-1.0.3-green.svg?style=flat)](https://github.com/YunoHost-Apps/borg_ynh/releases) [![Status](https://img.shields.io/badge/status-testing-yellow.svg?style=flat)](https://github.com/YunoHost-Apps/borg_ynh/milestones) @@ -12,15 +12,19 @@ An experimental borg implementation for yunohost ## Usage -If you want to backup your server A onto the server B. +If you want to backup your Server A onto the Server B, you need: +* Domain name of server B: serverB.local +* Name of the user that will be created on server B and that server A will use to ssh on server B: servera +* YunoHost names of apps you want to backup +* Frequency of your backups, see below -## Setup borg app on Server A +## Setup Borg Backup App on Server A -Firstly set up this app on the server A you want to backup: +Firstly set up the Borg Backup App (borg_ynh) on the server A you want to backup: ``` $ yunohost app install https://github.com/YunoHost-Apps/borg_ynh -Indicate the server where you want put your backups: serverB.local +Indicate the domain name of server B where to upload backups: serverB.local Indicate the ssh user to use to connect on this server: servera Indicate a strong passphrase, that you will keep preciously if you want to be able to use your backups: N0tAW3akp4ssw0rdYoloMacN!guets Would you like to backup your YunoHost configuration ? [0 | 1] (default: 1): @@ -28,6 +32,7 @@ Would you like to backup mails and user home directory ? [0 | 1] (default: 1): Which apps would you backup (list separated by comma or 'all') ? (default: all): Indicate the backup frequency (see systemd OnCalendar format) (default: Daily): ``` +## Syntax to define backup frequency You can schedule your backup by choosing an other frequency. Some example: @@ -47,20 +52,22 @@ Sat *-*-1..7 18:00:00 : The first saturday of every month at 18:00 See here for more info : https://wiki.archlinux.org/index.php/Systemd/Timers#Realtime_timer -At the end of the installation, the app display you the public_key and the user to give to the person who has access to the server B. +## Information generated by borg_ynh + +At the end of the installation, the app displays the public_key and the user to give to the person who has access to the server B. ``` You should now install the "Borg Server" app on serverb.local and fill questions like this: User: servera Public key: ssh-ed25519 AAAA[...] root@servera.local ``` - -If you don't find the mail and you don't see the message in the log bar you can found the public_key with this command: +This information is also sent by email to the admin of Server A. +If you don't find the mail and you don't see the message in the log bar you can find the public_key with this command: ``` $ cat /root/.ssh/id_borg_ed25519.pub ssh-ed25519 AAAA[...] root@servera.local ``` -## Setup Borg Server app on Server B +## Setup Borg Server App on Server B ``` $ yunohost app install https://github.com/YunoHost-Apps/borgserver_ynh @@ -70,14 +77,14 @@ Indicate the storage quota: 5G ``` ## Test -At this step your backup should schedule. +At this step your backup should run at the scheduled time. Note that the first backup can take very long, as many data have to be copied through ssh. Following backup are incremental, only additional data from to the last backup will be copied. -If you want to be sure, you can test it by running on server A: +If you don't want to wait for the scheduled time, you can test to backup by running on Server A: ``` $ service borg start ``` -Next you can check, your backup on server B +Next you can check presence of your backup on Server B: ``` $ borg list /home/servera/backup ``` @@ -90,4 +97,4 @@ yunohost app setting borg apps -v "nextcloud,wordpress" ## Backup on different server, and apply distinct schedule for apps -You can setup the borg apps several times on the same server so you can backup on several server or manage your frequency backup differently for specific part of your server. +You can setup the borg apps several times on the same server so you can backup on several server or manage your backup frequency differently for specific part of your server.