Setup dev environment
python3 -m pip install -r requirements.txt
pre-commit install
Run application
-
Backup
python3 -c "\ from auto_backup_storage import process_pair_in_pool;\ source_destination_pairs = [\ ('/mnt/C67881AE78819DB5/PIXAR/Vizgard/', '/mnt/90848C74848C5F1A/Vizgard/',),\ ('/mnt/C67881AE78819DB5/DISNEY/', '/mnt/404A81F44A81E74E/DISNEY/',),\ ('/mnt/C67881AE78819DB5/Downloads-Windows/', '/mnt/404A81F44A81E74E/Downloads-Windows/',),\ ('/mnt/00AE2C6B5AC8D335/', '/mnt/404A81F44A81E74E/365GB-SSD/',),\ ('/mnt/C67881AE78819DB5/PIXAR/', '/mnt/404A81F44A81E74E/PIXAR/',),\ ('/home/emoi/Downloads/', '/mnt/404A81F44A81E74E/Downloads-Ubuntu/',),\ ('/mnt/90848C74848C5F1A/4k/', '/mnt/404A81F44A81E74E/1TB-HDD/4K-videos',),\ ('/mnt/90848C74848C5F1A/8k/', '/mnt/404A81F44A81E74E/1TB-HDD/8K-videos',),\ ];\ process_pair_in_pool(source_destination_pairs);"
python3 -c "\
from auto_backup_storage import process_pair_in_pool;\
source_destination_pairs = [\
('/home/emoi/Downloads/Boost.Asio.Cpp.Network.Programming.Cookbook/', '/mnt/404A81F44A81E74E/Boost.Asio.Cpp.Network.Programming.Cookbook/',),\
];\
process_pair_in_pool(source_destination_pairs);"
-
Restore
- reverse source path, destination path
Build package
python3 setup.py sdist bdist_wheel
Publish package to Pypi
twine upload dist/*
Setup daemon
sudo nano /etc/systemd/system/auto-backup-storage.service
[Unit]
Description=Daemon for serving auto-backup-storage
After=network.target
[Service]
User=1000
Group=1000
ExecStart=/bin/bash -c "\
/home/emoi/anaconda3/bin/python3 -m pip install --upgrade auto-backup-storage && \
/home/emoi/anaconda3/bin/python3 -c 'from auto_backup_storage import process_pair_in_pool; source_destination_pairs = [\
(\"/mnt/C67881AE78819DB5/PIXAR/Vizgard/\", \"/mnt/90848C74848C5F1A/Vizgard/\"),\
(\"/mnt/C67881AE78819DB5/DISNEY/\", \"/mnt/404A81F44A81E74E/DISNEY/\"),\
(\"/mnt/C67881AE78819DB5/Downloads-Windows/\", \"/mnt/404A81F44A81E74E/Downloads-Windows/\"),\
(\"/mnt/00AE2C6B5AC8D335/\", \"/mnt/404A81F44A81E74E/365GB-SSD/\"),\
(\"/mnt/C67881AE78819DB5/PIXAR/\", \"/mnt/404A81F44A81E74E/PIXAR/\"),\
(\"/home/emoi/Downloads/\", \"/mnt/404A81F44A81E74E/Downloads-Ubuntu/\"),\
(\"/mnt/90848C74848C5F1A/4k/\", \"/mnt/404A81F44A81E74E/1TB-HDD/4K-videos\"),\
(\"/mnt/90848C74848C5F1A/8k/\", \"/mnt/404A81F44A81E74E/1TB-HDD/8K-videos\")]; \
process_pair_in_pool(source_destination_pairs);'"
ExecReload=/usr/bin/kill -s HUP $MAINPID
Restart=always
# RestartSec=60
[Install]
WantedBy=multi-user.target
sudo systemctl daemon-reload
sudo systemctl status auto-backup-storage.service
sudo journalctl -u auto-backup-storage.service
sudo systemctl start auto-backup-storage.service
sudo systemctl restart auto-backup-storage.service
sudo systemctl stop auto-backup-storage.service
sudo systemctl enable auto-backup-storage.service
sudo systemctl is-enabled auto-backup-storage.service
sudo systemctl disable auto-backup-storage.service
Executable file
From v0.1.6 I can backup with executable file
auto_backup_storage /path/to/source /path/to/destination
Docker environment
docker run -it --rm -v $(pwd):/workspace/auto_backup_storage python:3.12.7-alpine /bin/sh
apk update
cd /workspace/auto_backup_storage
python3 -m pip install setuptools
python3 setup.py sdist bdist_wheel
apk add twine
apk add gcc python3-dev musl-dev linux-headers
TWINE_USERNAME="__token__" TWINE_PASSWORD="pypi-....................................................." twine upload --non-interactive dist/*
Metadata
Release files for auto-backup-storage 1.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| auto_backup_storage-1.1.1.tar.gz | 12.5 kB | Without provenance | Details for auto_backup_storage-1.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| auto_backup_storage-1.1.1-py3-none-any.whl | Python 3 | none | any | Details for auto_backup_storage-1.1.1-py3-none-any.whl |
Total release size: 24.9 kB
Release files / auto_backup_storage-1.1.1.tar.gz
| Download URL | auto_backup_storage-1.1.1.tar.gz |
|---|---|
| Size | 12.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
56b7d380e9ed5f7d7f228c3958673be72a5461a65d9956eaa6cfc67200149faf
|
|
BLAKE2b-256 checksum How to use checksums |
3bb0365154ea384cbac9b0d75a9161e044653012737e8f44df2f8d438a127b1f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.12.7
|
Release files / auto_backup_storage-1.1.1-py3-none-any.whl
| Download URL | auto_backup_storage-1.1.1-py3-none-any.whl |
|---|---|
| Size | 12.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0befc1c4c8f72cb86bdd1d4a1d2a556ceee829aab77511f4a2da938d999977f0
|
|
BLAKE2b-256 checksum How to use checksums |
5981b5159f1a101eaf2ff80c3eed1d5133a1585258694470606492257b2c86ab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.12.7
|
Security for auto-backup-storage 1.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.