Update README.md

This commit is contained in:
2025-08-26 20:25:25 +00:00
parent 1aec74a53b
commit 975d85d76d

View File

@@ -1,3 +1,33 @@
# create_torrent # CIOS Torrent Creation Script
This script when run will create a .torrent file and a .magnet file from all folders that are under the root source directory (SOURCE_DIR). It will also set the tracker URL as defined by (TRACKER_URL). After each file is generated, it will copy then to both the (DEST_DIR) and the (TORRENT_WATCH_DIR). The script will also do a "chown" on (TORRENT_WATCH_DIR) to 1000:1000 so that the torrent client can pick up the torrents in realtime. We assume the (DEST_DIR) is the golden copy of the torrent files and the (TORRENT_WATCH_DIR) is a working folder that is watched by your torrent client.
# Dependencies
Will need transmission-cli for this to work
# Set the following static variables
```
SOURCE_DIR="/mnt/zpool0_nfs/cios_www"
DEST_DIR="/home/paulmataruso/TORRENT_BACKUP_GOLD"
TORRENT_WATCH_DIR="/home/paulmataruso/TORRENT_WATCH"
TRACKER_URL="http://tracker.dhitechnical.com:6969/announce"
```
# Make the script executable
```chmod +x create_torrent.sh```
# Run the script
```./create_torrent.sh```
This script will crawl though the SOURCE_DIR, then create a torrent file and a magnet link, it will set the hash size based on the source folder size. It will then copy the completed torrents to the DEST_DIR and the WATCH_DIR, it will also chown the WATCH_DIR with 1000:1000.