Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/simba77/backup-downloader
Downloads backups from a remote SFTP server and stores them for the required number of days.
https://github.com/simba77/backup-downloader
Last synced: about 17 hours ago
JSON representation
Downloads backups from a remote SFTP server and stores them for the required number of days.
- Host: GitHub
- URL: https://github.com/simba77/backup-downloader
- Owner: simba77
- Created: 2023-07-28T19:35:10.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-12-27T18:56:52.000Z (11 months ago)
- Last Synced: 2024-06-19T12:22:33.056Z (5 months ago)
- Language: Go
- Homepage:
- Size: 16.8 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Backup Downloader
Downloads backups from a remote SFTP server and stores them for the required number of days.
Thus, one copy can be stored on the main server to save space, and as many copies as you want on the backup server.This version is currently intended for backups created by the Hestia control panel.
## Build
Change the target platforms in the file: build.sh (if you need)
```
platforms=("linux/amd64" "darwin/amd64")
```Run the build command
```shell
sh build.sh
```The binary files will appear in the build directory.
## Run
Copy the [config.json.example](config.json.example) file to any folder you wish.
Rename file to config.json and change it.
Run a binary file with the CONFIG_PATH environment variable
```shell
CONFIG_PATH=/path/to/config ./linux-amd64
```## Service example
```shell
systemctl edit --full --force backuper.service
```Config example
Change the ExecStart and Environment parameters
```
[Unit]
Description=Backuper
Wants=network-online.target
After=network-online.target
[Service]
Environment="CONFIG_PATH=/backups"
User=root
Group=root
Type=simple
ExecStart=/backups/backuper
[Install]
WantedBy=multi-user.target
``````shell
systemctl daemon-reload
``````shell
systemctl start backuper
```Enable autostart
```shell
systemctl enable backuper
```