diff --git a/scripts/utils/link-systemd.sh b/scripts/utils/link-systemd.sh index 72384cd8..d00c1284 100755 --- a/scripts/utils/link-systemd.sh +++ b/scripts/utils/link-systemd.sh @@ -29,12 +29,6 @@ fi echo "๐Ÿ” Creating symbolic links for AITBC systemd files..." -# Create backup of current active systemd files -BACKUP_DIR="/opt/aitbc/systemd-backup-$(date +%Y%m%d-%H%M%S)" -echo "๐Ÿ“ฆ Creating backup: $BACKUP_DIR" -mkdir -p "$BACKUP_DIR" -find "$ACTIVE_SYSTEMD_DIR" -name "aitbc-*" -type f -exec cp {} "$BACKUP_DIR/" \; 2>/dev/null || true - # Remove existing aitbc-* files (but not directories) echo "๐Ÿงน Removing existing systemd files..." find "$ACTIVE_SYSTEMD_DIR" -name "aitbc-*" -type f -delete 2>/dev/null || true @@ -105,11 +99,10 @@ fi echo echo "โœ… Systemd linking completed!" echo -echo "๐Ÿ“Š Link Summary:" +echo "๐Ÿ“Š Linking Summary:" echo " Linked files: $linked_files" echo " Repository: $REPO_SYSTEMD_DIR" echo " Active: $ACTIVE_SYSTEMD_DIR" -echo " Backup location: $BACKUP_DIR" echo echo "๐ŸŽฏ Benefits:" echo " โœ… Active systemd files always match repository" @@ -129,10 +122,6 @@ echo echo "๐Ÿ” To verify links:" echo " ls -la /etc/systemd/system/aitbc-*" echo " readlink /etc/systemd/system/aitbc-blockchain-node.service" -echo -echo "โš ๏ธ If you need to restore backup:" -echo " sudo cp $BACKUP_DIR/* /etc/systemd/system/" -echo " sudo systemctl daemon-reload" # Ensure script exits successfully if [[ $linked_files -gt 0 ]]; then