diff --git a/hostspatch/all/usr/sbin/hostspatch.sh b/hostspatch/all/usr/sbin/hostspatch.sh deleted file mode 100755 index 5b05567..0000000 --- a/hostspatch/all/usr/sbin/hostspatch.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/usr/bin/env bash - -# Define the entries to be added -ENTRIES=("127.0.0.1 checkip.synology.com" "::1 checkipv6.synology.com" "127.0.0.1 dlid.synology.com") - -# Loop over each entry -for ENTRY in "${ENTRIES[@]}" -do - if [ -f /etc/hosts ]; then - # Check if the entry is already in the file - if grep -Fxq "$ENTRY" /etc/hosts; then - echo "Entry $ENTRY already exists" - else - echo "Entry $ENTRY does not exist, adding now" - echo "$ENTRY" >> /etc/hosts - fi - fi - if [ -f /etc.defaults/hosts ]; then - if grep -Fxq "$ENTRY" /etc.defaults/hosts; then - echo "Entry $ENTRY already exists" - else - echo "Entry $ENTRY does not exist, adding now" - echo "$ENTRY" >> /etc.defaults/hosts - fi - fi -done - -exit 0 \ No newline at end of file diff --git a/hostspatch/install.sh b/hostspatch/install.sh deleted file mode 100755 index 31e47f0..0000000 --- a/hostspatch/install.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/usr/bin/env ash - -if [ "${1}" = "late" ]; then - echo "Creating service to exec Hostspatch" - cp -vf /usr/sbin/hostspatch.sh /tmpRoot/usr/sbin/hostspatch.sh - - DEST="/tmpRoot/lib/systemd/system/hostspatch.service" - echo "[Unit]" >${DEST} - echo "Description=Enable Hostspatch" >>${DEST} - echo >>${DEST} - echo "[Service]" >>${DEST} - echo "Type=oneshot" >>${DEST} - echo "RemainAfterExit=yes" >>${DEST} - echo "ExecStart=/usr/sbin/hostspatch.sh" >>${DEST} - echo >>${DEST} - echo "[Install]" >>${DEST} - echo "WantedBy=multi-user.target" >>${DEST} - - mkdir -vp /tmpRoot/lib/systemd/system/multi-user.target.wants - ln -vsf /lib/systemd/system/hostspatch.service /tmpRoot/lib/systemd/system/multi-user.target.wants/hostspatch.service -fi \ No newline at end of file diff --git a/hostspatch/manifest.yml b/hostspatch/manifest.yml deleted file mode 100644 index e92ad4c..0000000 --- a/hostspatch/manifest.yml +++ /dev/null @@ -1,19 +0,0 @@ -version: 1 -name: hostspatch -description: "Prevent DSM from calling Home" -system: false -beta: false -all: - install-script: "install.sh" - copy: "all" -apollolake: true -broadwell: true -broadwellnk: true -broadwellnkv2: true -broadwellntbap: true -denverton: true -geminilake: true -purley: true -v1000: true -r1000: true -epyc7002: true \ No newline at end of file