-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserverless.yml
53 lines (49 loc) · 1.57 KB
/
serverless.yml
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
service: troep
configValidationMode: error
provider:
name: aws
# The AWS region in which to deploy (us-east-1 is the default)
region: eu-west-3
# The stage of the application, e.g. dev, production, staging… ('dev' is the default)
stage: production
runtime: provided.al2
lambdaHashingVersion: 20201221
apiGateway:
binaryMediaTypes:
- '*/*'
environment:
APP_KEY: ${env:APP_KEY}
APP_NAME: ${env:APP_NAME}
AWS_BUCKET: ${env:AWS_BUCKET}
BREF_BINARY_RESPONSES: '1'
DEBUG_IPS: ${env:DEBUG_IPS}
MAIL_FROM_ADDRESS: ${env:MAIL_FROM_ADDRESS}
MAIL_TO_ADDRESS: ${env:MAIL_TO_ADDRESS}
PROXY_COUNT: ${env:PROXY_COUNT}
REAL_AWS_ACCESS_KEY_ID: ${env:REAL_AWS_ACCESS_KEY_ID}
REAL_AWS_SECRET_ACCESS_KEY: ${env:REAL_AWS_SECRET_ACCESS_KEY}
package:
patterns:
# Directories to exclude from deployment
- '!database/**'
- '!node_modules/**'
- '!tests/**'
functions:
# This function runs the Laravel website/API
web:
handler: public/index.php
timeout: 28 # in seconds (API Gateway has a timeout of 29 seconds)
layers:
- ${bref:layer.php-84-fpm}
events:
- httpApi: '*'
# This function lets us run artisan commands in Lambda
artisan:
handler: artisan
timeout: 120 # in seconds
layers:
- ${bref:layer.php-84} # PHP
- ${bref:layer.console} # The "console" layer
plugins:
# We need to include the Bref plugin
- ./vendor/bref/bref