Orchestrated provisioning and deprovisioning in external databases using custom scripts