Move common simple deployment code to helper.