Files
backupscript/README.md
Jens True 580653bbea
Some checks failed
ci/woodpecker/push/docker Pipeline was successful
ci/woodpecker/push/test Pipeline failed
New container
2025-04-01 12:51:38 +00:00

48 lines
1.4 KiB
Markdown

# Backup script
[![Build status](https://build.jcktrue.dk/api/badges/jct/backupscript/status.svg)](https://build.jcktrue.dk/jct/backupscript)
Backup script utilizing Rclone to backup local file systems and send notifications.
# Minimum requirements
- PHP8.4
- Composer to install required packages.
- Rclone installed
# Rclone install
wget https://downloads.rclone.org/rclone-current-linux-amd64.deb
sudo dpkg -i rclone-current-linux-amd64.deb
rm rclone-current-linux-amd64.deb
# For development
# PHP latest for debian
curl -sSL https://packages.sury.org/php/README.txt | sudo bash -x
sudo apt update
sudo apt upgrade
sudo apt install php8.34-cli php8.4-xml php8.34-curl php8.4-zip php8.4-xdebug php8.4-mbstring unzip wget graphviz plantuml
# PHP Docs
rm phpDocumentor.phar
wget https://phpdoc.org/phpDocumentor.phar
chmod +x phpDocumentor.phar
# Infection install
rm infection.phar
wget https://github.com/infection/infection/releases/download/0.27.8/infection.phar
chmod +x infection.phar
# PHP CopyPasteDetector install
rm phpcpd.phar
wget https://phar.phpunit.de/phpcpd.phar
chmod +x phpcpd.phar
# Test, analyze, metrics, document
./composer.phar test-full && ./composer.phar analyze && ./composer.phar metrics && ./composer.phar doc
# Using Docker
docker run --rm -v /srv/raid/:/srv/raid/ -v /home/jct/dockersetup/backup:/config/ code.jcktrue.dk/jct/backupscript:latest backup /config/config.yml