allow get_function for lambda created with zipfile
This commit is contained in:
parent
68907cfe09
commit
2c8326e9b9
2 changed files with 58 additions and 7 deletions
|
|
@ -111,13 +111,18 @@ class LambdaFunction(BaseModel):
|
|||
}
|
||||
|
||||
def get_code(self):
|
||||
return {
|
||||
"Code": {
|
||||
"Location": "s3://lambda-functions.aws.amazon.com/{0}".format(self.code['S3Key']),
|
||||
"RepositoryType": "S3"
|
||||
},
|
||||
"Configuration": self.get_configuration(),
|
||||
}
|
||||
if 'S3Key' in self.code:
|
||||
return {
|
||||
"Code": {
|
||||
"Location": "s3://lambda-functions.aws.amazon.com/{0}".format(self.code['S3Key']),
|
||||
"RepositoryType": "S3"
|
||||
},
|
||||
"Configuration": self.get_configuration(),
|
||||
}
|
||||
else:
|
||||
return {
|
||||
"Configuration": self.get_configuration(),
|
||||
}
|
||||
|
||||
def convert(self, s):
|
||||
try:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue