Skip to content
This repository was archived by the owner on Nov 29, 2023. It is now read-only.

Commit cc7c8df

Browse files
committed
Merge remote-tracking branch 'node-aws-lambda-graphql-sapling/master'
2 parents d908afb + 16f5eb5 commit cc7c8df

File tree

1 file changed

+25
-15
lines changed

1 file changed

+25
-15
lines changed

serverless.yml

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,14 @@ provider:
99
name: aws
1010
runtime: nodejs12.x
1111
profile: serverless
12-
stage: test
12+
stage: dev
1313
region: us-east-1
1414

1515
custom:
1616
stage: ${opt:stage, self:provider.stage}
1717
domainName: ${self:custom.domainNameStage.${self:custom.stage}}
1818
domainNameStage:
19+
dev: dev-api.${self:custom.baseDomainName}
1920
test: test-api.${self:custom.baseDomainName}
2021
prod: api.${self:custom.baseDomainName}
2122
baseDomainName: codesaplings.com
@@ -25,6 +26,15 @@ custom:
2526
basePath: todo
2627
stage: ${self:custom.stage}
2728
createRoute53Record: true
29+
environmentValues: ${self:custom.environmentValuesStage.${self:custom.stage}}
30+
environmentValuesStage:
31+
dev:
32+
NODE_ENV: development
33+
test:
34+
NODE_ENV: test
35+
prod:
36+
NODE_ENV: production
37+
2838
documentation:
2939
info:
3040
title: node-aws-lambda-graphql-example-todo
@@ -35,18 +45,18 @@ functions:
3545
graphql:
3646
handler: dist/events/apollo.handler
3747
events:
38-
- http:
39-
path: graphql
40-
method: get
41-
cors: true
42-
documentation:
43-
summary: GraphQL Server
44-
description: GraphQL Server
48+
- http:
49+
path: graphql
50+
method: get
51+
cors: true
52+
documentation:
53+
summary: GraphQL Server
54+
description: GraphQL Server
4555

46-
- http:
47-
path: graphql
48-
method: post
49-
cors: true
50-
documentation:
51-
summary: GraphQL Server
52-
description: GraphQL Server
56+
- http:
57+
path: graphql
58+
method: post
59+
cors: true
60+
documentation:
61+
summary: GraphQL Server
62+
description: GraphQL Server

0 commit comments

Comments
 (0)