MODS SPK Tracer - vletroye/SynoPackages GitHub Wiki
Description
Coming soon (or later)... This package is tracing its own steps during installation/upgrade/removal, for learning purpose... Each step being one of the scripts: start-stop-status, preinst, postinst, preupgrade, postupgrade, preuninst, postuninst
Ex.:
1. For an installation, with variable $SYNOPKG_PKG_STATUS = "INSTALL"
- the new installation wizard
- the new preinst in the temp /volume1/@tmp/pkginstall/scripts
- the new postinst now ready in /var/packages/[package name]/scripts
- the new start-stop-status 'log' in /var/packages/[package name]/scripts (Could possibly be called later)
- the new start-stop-status 'status' in /var/packages/[package name]/scripts
- the new start-stop-status 'start' in /var/packages/[package name]/scripts
2. For an Upgrade, with variable $SYNOPKG_PKG_STATUS = "UPGRADE"
- the new upgrade wizard
- the old start-stop-status 'stop' still in /var/packages/[package name]/scripts
- the new preupgrade in the temp /volume1/@tmp/pkginstall/scripts
- the old preuninst still in /var/packages/[package name]/scripts
- the old postuninst still in /var/packages/[package name]/scripts
- the new preinst in the temp /volume1/@tmp/pkginstall/scripts
- the new postinst now ready in /var/packages/[package name]/scripts
- the new postupgrade in /var/packages/[package name]/scripts
- the new start-stop-status 'log' already in /var/packages/[package name]/scripts (Could possibly be called later)
- the new start-stop-status 'status' already in /var/packages/[package name]/scripts
- the new start-stop-status 'start' already in /var/packages/[package name]/scripts
3. For an Uninstallation, with variable $SYNOPKG_PKG_STATUS="UNINSTALL"
- the old uninstallation wizard
- the old start-stop-status 'stop' still in /var/packages/[package name]/scripts
- the old preuninst still in /var/packages/[package name]/scripts
- the old postuninst still in /var/packages/[package name]/scripts
Folder created for the packages:
- /usr/syno/etc/packages/[package name]/ is created if it does not exist. It is not deleted automatically and can be used to keep files between installations or during upgrades.
- /volume1/@appstore/[package name]/ is created to deploy the application contained in the package. It is deleted during an upgrade or by the uninstallation.
- /usr/syno/synoman/webman/3rdparty/[package name] -> /volume1/@appstore/[package name]/target/[dmsuidir]/ is created during installation and removed after uninstallation.
- /var/packages/[package name]/ is the folder where the package is installed (with its scripts, wizards, etc...)
- conf/
- enabled (a file created if the package is "started". It is deleted when one stops the package)
- etc -> /usr/syno/etc/packages/[package name]/
- INFO
- scripts/
- target -> /volume1/@appstore/[package name]/
- WIZARD_UIFILES
Sources
Find the source code here