I am setting up the Azure pipeline for NodeJS Serverless to AWS Lambda deployment using this AWS Document. During the deployment, getting an error with "[Errno 13] Permission denied":
When I check the log file, the error message is:
2024-03-28T10:11:10.4825015Z
##[debug]Failed collecting file(s) due to error:
[('/run/cloud-init/combined-cloud-config.json',
'/tmp/tmpze59c06e/cloud-init-logs-2024-03-28/run/cloud-init/combined-cloud-config.json',
"[Errno 13] Permission denied: '/run/cloud-init/combined-cloud-config.json'"),
('/run/cloud-init/network-config.json',
'/tmp/tmpze59c06e/cloud-init-logs-2024-03-28/run/cloud-init/network-config.json',
"[Errno 13] Permission denied: '/run/cloud-init/network-config.json'")]
And Yaml code is here:
trigger:
- Branch Name
pool:
vmImage: ubuntu-latest
steps:
- task: LambdaDeployFunction@1
inputs:
awsCredentials: 'Credential Name'
regionName: 'region'
deploymentMode: 'codeonly'
functionName: 'function name here'
codeLocation: 'localfile'
- script: |
npm install
npm install -g serverless
serverless config credentials --provider aws --key DummyKeyHere --secret DummySecretKey
serverless deploy --stage local --region eu-west-1
displayName: 'Deploy to AWS'
Not sure what permission is missing.
