moved check_before_deployment call to deployment task