Posted on 04-27-2020 10:55 AM
I created a pkg that will deploy Snagit 2020 and with post-install to remove some plugins and disable users from adding new ones. So pretty simple pkg I attached the screenshot.
The issue is that Snagit is not copied to the Application dir.
No issues at the end of the setup. Postinstall is working.
Posted on 04-27-2020 11:23 AM
Are you copying it to the ~/Applications/ folder or the /Applications folder?
Posted on 04-27-2020 10:26 PM
Hi @yarin ,
Was this app built in Composer? Also, is the postinstall script the only thing that modifies the app? Modifying apps gets tricky with Apple's notarization. Any modified piece of the app can lead to packages and apps not properly being installed.
Does the app install properly without the postinstall?
Posted on 04-28-2020 03:58 AM
I built it just like the rest of my apps with buildpkg and not Composer.
I copy the files to /Applications and not ~/Applicatoins/
The PostInstall only do "chmod 555 to /Applications/Snagiit 2020.app/Plugins/*"
The Preinstall only do killall "Snagit 2020" (something like that)
Posted on 04-28-2020 04:34 AM
755
and root:admin
is the usual way to set things that you put into /Applications
.
If the app was distributed on a DMG, might want to mount the DMG as the source, and drag the app from the mounted DMG into Composer without making any changes.
If your source is /Applications/Snagit 2020.app
, depending on how the app got there, the owner:group
and permissions might be bonked. To set /Applications/Snagit 2020.app
(source) permissions:
sudo find /Applications/Snagit 2020.app -type d -print0 | xargs -0 chmod 755
sudo find /Applications/Snagit 2020.app -type f -print0 | xargs -0 chmod 644
This way you're not doing a recursive 755
which would set non-executables to executable, and you won't be creating globally writable folders in /Applications/
which would raise a flag if you're audited.
PS, not sure but guessing 555
was a typo. :)