Automating resource and security configuration of serverless applications