make readYAML a helper function and write deploy script