release/qa:
- step:
name: Build and package
script:
- apt-get update && apt-get install -y zip
- zip {files}
artifacts:
- file.zip
- pipe.meta.env
- step:
name: Update DEV Lambda
script:
# Update lambda code and publish a new version
- pipe: atlassian/aws-lambda-deploy:1.10.0
variables:
AWS_ACCESS_KEY_ID: {key id}
AWS_SECRET_ACCESS_KEY: {key}
AWS_DEFAULT_REGION: {region}
FUNCTION_NAME: {function name}
COMMAND: 'update'
ZIP_FILE: 'file.zip'
WAIT: 'true'
- step:
name: Update QA Version
script:
# Update lambda code and publish a new version
- pipe: atlassian/aws-lambda-deploy:1.10.0
variables:
AWS_ACCESS_KEY_ID: {key id}
AWS_SECRET_ACCESS_KEY: {key}
AWS_DEFAULT_REGION: {region}
FUNCTION_NAME: {function_name}
COMMAND: 'alias'
ALIAS: 'qa'
WAIT: 'true'
I have been trying a few different things but end results always gives the same error.
✔ Lambda is ready for deployment.
INFO: Checking for existing lambda alias.
INFO: Existing alias found - updating alias.
Traceback (most recent call last):
File "/pipe.py", line 341, in <module>
pipe.run()
File "/pipe.py", line 324, in run
self.update_or_create_alias()
File "/pipe.py", line 159, in update_or_create_alias
self.update_alias()
File "/pipe.py", line 172, in update_alias
self.client.update_alias(
File "/usr/local/lib/python3.10/site-packages/botocore/client.py", line 530, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/usr/local/lib/python3.10/site-packages/botocore/client.py", line 923, in _make_api_call
request_dict = self._convert_to_request_dict(
File "/usr/local/lib/python3.10/site-packages/botocore/client.py", line 991, in _convert_to_request_dict
request_dict = self._serializer.serialize_to_request(
File "/usr/local/lib/python3.10/site-packages/botocore/validate.py", line 381, in serialize_to_request
raise ParamValidationError(report=report.generate_report())
botocore.exceptions.ParamValidationError: Parameter validation failed:
Invalid length for parameter FunctionVersion, value: 0, valid min length: 1
Honestly just not sure what to do at this point because I tried
Read results from the update pipe into environment variables
But that didn't work either. Any suggestions would be great and of much help.