From 11595024af3da937307d5bb01e0009db2410984b Mon Sep 17 00:00:00 2001 From: AuxXxilium Date: Sat, 31 Aug 2024 09:49:06 +0200 Subject: [PATCH] allowdowngrade: add new Signed-off-by: AuxXxilium --- allowdowngrade/all/usr/bin/allowdowngrade.sh | 17 ++++++++ allowdowngrade/install.sh | 42 ++++++++++++++++++++ allowdowngrade/manifest.yml | 19 +++++++++ misc/install.sh | 6 --- 4 files changed, 78 insertions(+), 6 deletions(-) create mode 100755 allowdowngrade/all/usr/bin/allowdowngrade.sh create mode 100755 allowdowngrade/install.sh create mode 100644 allowdowngrade/manifest.yml diff --git a/allowdowngrade/all/usr/bin/allowdowngrade.sh b/allowdowngrade/all/usr/bin/allowdowngrade.sh new file mode 100755 index 0000000..7b3f396 --- /dev/null +++ b/allowdowngrade/all/usr/bin/allowdowngrade.sh @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +# +# Copyright (C) 2023 AuxXxilium +# +# This is free software, licensed under the MIT License. +# See /LICENSE for more information. +# + +# Allow VideoStation Downgrade on DSM 7.2.2 +/usr/syno/bin/synosetkeyvalue /etc.defaults/synopackageslimit.conf VideoStation "3.1.0-3153" +/usr/syno/bin/synosetkeyvalue /etc/synopackageslimit.conf VideoStation "3.1.0-3153" +# Allow AME Downgrade on DSM 7.2.2 +/usr/syno/bin/synosetkeyvalue /etc.defaults/synopackageslimit.conf CodecPack "3.1.0-3005" +/usr/syno/bin/synosetkeyvalue /etc/synopackageslimit.conf CodecPack "3.1.0-3005" +# Allow Surveillance Station Downgrade on DSM 7.2.2 +/usr/syno/bin/synosetkeyvalue /etc.defaults/synopackageslimit.conf SurveillanceStation "9.2.0-11289" +/usr/syno/bin/synosetkeyvalue /etc/synopackageslimit.conf SurveillanceStation "9.2.0-11289" \ No newline at end of file diff --git a/allowdowngrade/install.sh b/allowdowngrade/install.sh new file mode 100755 index 0000000..679774d --- /dev/null +++ b/allowdowngrade/install.sh @@ -0,0 +1,42 @@ +#!/usr/bin/env ash +# +# Copyright (C) 2023 AuxXxilium +# +# This is free software, licensed under the MIT License. +# See /LICENSE for more information. +# + +if [ "${1}" = "late" ]; then + echo "Installing addon allowdowngrade - ${1}" + mkdir -p "/tmpRoot/usr/arc/addons/" + cp -vf "${0}" "/tmpRoot/usr/arc/addons/" + + cp -vf /usr/bin/allowdowngrade.sh /tmpRoot/usr/bin/allowdowngrade.sh + + mkdir -p "/tmpRoot/usr/lib/systemd/system" + DEST="/tmpRoot/usr/lib/systemd/system/allowdowngrade.service" + cat << EOF > ${DEST} +[Unit] +Description=addon allowdowngrade +After=multi-user.target + +[Service] +User=root +Type=oneshot +RemainAfterExit=yes +ExecStart=/usr/bin/allowdowngrade.sh + +[Install] +WantedBy=multi-user.target + +[X-Synology] +Author=Virtualization Team +EOF + + mkdir -vp /tmpRoot/usr/lib/systemd/system/multi-user.target.wants + ln -vsf /usr/lib/systemd/system/allowdowngrade.service /tmpRoot/usr/lib/systemd/system/multi-user.target.wants/allowdowngrade.service +fi +elif [ "${1}" = "uninstall" ]; then + echo "Installing addon allowdowngrade - ${1}" + # To-Do +fi \ No newline at end of file diff --git a/allowdowngrade/manifest.yml b/allowdowngrade/manifest.yml new file mode 100644 index 0000000..9549c42 --- /dev/null +++ b/allowdowngrade/manifest.yml @@ -0,0 +1,19 @@ +version: 1 +name: allowdowngrade +description: "Allow Downgrade for AME, SS and VideoStation on 7.2.2" +system: false +beta: true +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 diff --git a/misc/install.sh b/misc/install.sh index 63b518d..43d5825 100755 --- a/misc/install.sh +++ b/misc/install.sh @@ -280,12 +280,6 @@ elif [ "${1}" = "late" ]; then echo "synosystemd.conf does not exist." fi - # Allow VideoStation install and AME Downgrade on DSM 7.2.2 - /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc.defaults/synopackageslimit.conf VideoStation "3.1.0-3153" - /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc/synopackageslimit.conf VideoStation "3.1.0-3153" - /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc.defaults/synopackageslimit.conf CodecPack "3.1.0-3005" - /tmpRoot/usr/syno/bin/synosetkeyvalue /tmpRoot/etc/synopackageslimit.conf CodecPack "3.1.0-3005" - # Community Packages if [ ! -f /tmpRoot/usr/syno/etc/packages/feeds ]; then mkdir -p /tmpRoot/usr/syno/etc/packages