+ Start a Discussion
Enkhbold Tsagaach 1Enkhbold Tsagaach 1 

Question about InstallHandler & Sandbox

If an installed managed package is deployed from sandbox to production what happens to post install script? Is it count as upgrade (context.isUpgrade) or the script never runs on production (maybe doesn't count as install since it's not actually installing in production)?

We have a postinstall script that do some stuff on only new install (!context.isUpgrade() && !context.isPush())

But it's not working when the package is installed in sandbox first and then deployed to production
Yury BondarauYury Bondarau
How are you going to deploy installed package from sandbox to production? Will you use Metadata API (http://www.salesforce.com/us/developer/docs/api_meta/Content/meta_installedpackage.htm)?

Why don't you simply install the package on production?