Skip to content

Commit

Permalink
adding support for Environment Variables
Browse files Browse the repository at this point in the history
  • Loading branch information
KingMonty committed Jan 15, 2024
1 parent 22f1e70 commit d672b7a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ const main = async (): Promise<void> => {
zipPath: core.getInput('zip-path') || undefined,
aliasName: core.getInput('alias-name'),
aliasDescription: core.getInput('alias-description'),
environmentVariables: core.getInput('environment-variables'),
})
core.setOutput('function-version', outputs.functionVersion)
core.setOutput('function-version-arn', outputs.functionVersionARN)
Expand Down
3 changes: 3 additions & 0 deletions src/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ export const run = async (inputs: Inputs): Promise<Outputs> => {
}

const updateFunctionConfiguration = async (client: LambdaClient, inputs: Inputs) => {
if (!inputs.environmentVariables) {
return
}
core.info(`Updating function ${inputs.functionName} configuration`)
return await client.send(
new UpdateFunctionCodeCommand({
Expand Down

0 comments on commit d672b7a

Please sign in to comment.