Structuring monorepo better

This commit is contained in:
2020-02-06 08:24:25 +11:00
parent ee28ec6c8c
commit f8ea793de9
8 changed files with 36 additions and 17042 deletions

11
.gitignore vendored
View File

@ -34,6 +34,8 @@ build/Release
# Dependency directories # Dependency directories
node_modules/ node_modules/
node_modules_pc/
node_modules_surface/
jspm_packages/ jspm_packages/
# Typescript v1 declaration files # Typescript v1 declaration files
@ -57,10 +59,7 @@ typings/
# dotenv environment variables file # dotenv environment variables file
.env .env
# custom
dist/
/package-lock.json /package-lock.json
/dist /nbproject/private/
src/private/dist .vscode
src/public/public .serverless
.cache

View File

@ -11,6 +11,8 @@ cache:
matrix: matrix:
include: include:
- env: PROJECT=src/private/ - env: PROJECT=src/private/
include:
- env: PROJECT=src/public/
install: install:
- cd $PROJECT - cd $PROJECT

3
src/private/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
dist/
*.log
*.lock

View File

@ -7,7 +7,7 @@ package:
excludeDevDependencies: false excludeDevDependencies: false
individually: true individually: true
include: include:
- backend/dist/** - dist/**
provider: provider:
name: aws name: aws
@ -26,26 +26,20 @@ provider:
functions: functions:
ping: ping:
handler: backend/dist/index.ping handler: dist/index.ping
events: events:
- http: ANY ping - http: ANY ping
sendMail: sendMail:
handler: backend/dist/functions/mail/send.sendMail handler: dist/functions/mail/send.sendMail
events: events:
- http: ANY mail/send - http: ANY mail/send
plugins: plugins:
- serverless-plugin-include-dependencies - serverless-plugin-include-dependencies
- serverless-offline - serverless-offline
- serverless-finch
custom: custom:
ssm: '/aws/reference/secretsmanager/prod.domsPlace.' ssm: '/aws/reference/secretsmanager/prod.domsPlace.'
client:
bucketName: domsplace-${self:provider.stage}-${self:provider.region}-public
distributionFolder: frontned/public/
indexDocument: index.html
errorDocument: index.html
serverless-offline: serverless-offline:
disableCookieValidation: true disableCookieValidation: true
port: 3001 port: 3001

File diff suppressed because it is too large Load Diff

2
src/public/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
public/
*.lock

21
src/public/serverless.yml Normal file
View File

@ -0,0 +1,21 @@
org: yourwishes
service: domsplace
frameworkVersion: ">=1.26.0"
package:
excludeDevDependencies: false
individually: true
include:
- public/**
plugins:
- serverless-plugin-include-dependencies
- serverless-finch
custom:
client:
bucketName: domsplace-${self:provider.stage}-${self:provider.region}-public
distributionFolder: frontned/public/
indexDocument: index.html
errorDocument: index.html

File diff suppressed because it is too large Load Diff