Skip to content

Instantly share code, notes, and snippets.

@keithrozario
Created September 8, 2019 10:08
Show Gist options
  • Save keithrozario/4e4eda7b3452f4f772f48505a9d39c83 to your computer and use it in GitHub Desktop.
Save keithrozario/4e4eda7b3452f4f772f48505a9d39c83 to your computer and use it in GitHub Desktop.
publish_github.yml
publish_github:
handler: publish_to_github.handler
runtime: provided
memorySize: 2048
timeout: 600
environment:
GITHUB_REPO: ${self:custom.githubRepo}
KEK_PARAMETER: ${self:custom.kekParameter}
S3_KEYS: ${self:custom.s3KeysName}
BUCKET_NAME: ${self:custom.s3LayersName}
iamRoleStatementsName: ${self:provider.stage}-publish_github
iamRoleStatements:
- Effect: Allow
Action:
- s3:GetObject
Resource: ${self:custom.s3LayersArn}/*
- Effect: Allow
Action:
- s3:ListBucket
Resource: ${self:custom.s3LayersArn}
- Effect: Allow
Action:
- ssm:GetParameters
- ssm:GetParameter
Resource:
Fn::Join:
- ":"
- - arn:aws:ssm
- ${self:provider.region}
- Ref: AWS::AccountId
- parameter${self:custom.kekParameter}
- Effect: Allow
Action:
- s3:GetObject
Resource: ${self:custom.s3KeysArn}/*
layers:
- arn:aws:lambda:${self:provider.region}:744348701589:layer:bash:8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment