-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserverless.yml
More file actions
109 lines (99 loc) · 2.86 KB
/
serverless.yml
File metadata and controls
109 lines (99 loc) · 2.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
frameworkVersion: "^3.43.1"
service: serverless-github-check
plugins:
- serverless-esbuild
- serverless-offline
provider:
name: aws
runtime: nodejs24.x
profile: default
region: ${opt:region, 'eu-west-1'}
logRetentionInDays: 30
versionFunctions: false
deploymentMethod: direct
architecture: arm64
memorySize: 128
environment:
NAMESPACE: 20 Minutes
# SecureString from SSM Parameters
GITHUB_TOKEN: ${ssm:GITHUB_TOKEN}
package:
individually: true
custom:
esbuild:
bundle: true
sourcemap: true
minify: true
target: node24
platform: node
format: esm
outputFileExtension: .mjs
banner:
js: "import { createRequire } from 'module';const require = createRequire(import.meta.url);"
exclude:
- '@aws-sdk/*'
- '@aws-crypto/*'
packager: yarn
installExtraArgs:
- '--frozen-lockfile'
functions:
specification:
handler: functions/specification.handler
description: Validate GitHub PRs against some specifications
environment:
CHECK_BODY_LENGTH: 8
CHECK_TITLE_LENGTH: 8
events:
-
# default event
http:
path: webhook
method: post
cors: true
-
http:
path: webhook/specification
method: post
cors: true
label:
handler: functions/label.handler
description: Check for GitHub PR labels to block merge
environment:
# comma separated labels
BLOCK_LABELS: "Work In Progress,Waiting For Change,Waiting For Travis,Do Not Merge,Blocked"
events:
-
http:
path: webhook/label
method: post
cors: true
fixup:
handler: functions/fixup.handler
description: Ensure no "fixup!" commits are in the PR
timeout: 10
events:
-
http:
path: webhook/fixup
method: post
cors: true
autoMerge:
handler: functions/auto-merge.handler
description: Automatically merge Dependabot PR
events:
-
http:
path: webhook/auto-merge
method: post
cors: true
artifacts:
handler: functions/artifacts.handler
description: Check if an artifact in deps to block merge
environment:
ARTIFACTS_REGEX: '(fixtures\.20mn\.it|localhost:)'
events:
-
http:
path: webhook/artifacts
method: post
cors: true