forked from fr/deguapp
Addded: .env.example, fixed build
This commit is contained in:
parent
96900fd3b3
commit
3227854086
1
api/.gitignore
vendored
1
api/.gitignore
vendored
@ -1,3 +1,4 @@
|
||||
node_modules/
|
||||
dist/
|
||||
package-lock.json
|
||||
.env
|
||||
|
@ -11,7 +11,7 @@
|
||||
"start:prod": "node dist/server.js",
|
||||
"tsc": "tsc -p .",
|
||||
"clean": "rimraf dist",
|
||||
"copy-assets": "ts-node src/utils/copyAssets",
|
||||
"copy-assets": "ts-node src/utils/copy_assets",
|
||||
"build": "npm-run-all clean tsc copy-assets",
|
||||
"test": "npx jest . --runInBand",
|
||||
"format": "npx prettier --write ."
|
||||
|
6
api/src/.env.example
Normal file
6
api/src/.env.example
Normal file
@ -0,0 +1,6 @@
|
||||
APP_PORT=6060
|
||||
APP_HOST=127.0.0.1
|
||||
|
||||
JWT_SECRET=generate_random_secret
|
||||
|
||||
DB_URI='mongodb://username:password@localhost:27017/database?authSource=admin'
|
6
api/src/utils/copy_assets.ts
Normal file
6
api/src/utils/copy_assets.ts
Normal file
@ -0,0 +1,6 @@
|
||||
import * as shell from 'shelljs';
|
||||
|
||||
// Copy all the view templates
|
||||
//shell.cp('-R', 'src/views', 'dist/')
|
||||
//shell.cp('-R', 'src/public', 'dist/');
|
||||
shell.cp('-u', 'src/.env', 'dist/');
|
@ -7,9 +7,12 @@
|
||||
"strict": true /* Enable all strict type-checking options. */,
|
||||
"baseUrl": "./" /* Base directory to resolve non-absolute module names. */,
|
||||
"esModuleInterop": true /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables `allowSyntheticDefaultImports` for type compatibility. */,
|
||||
"resolveJsonModule": true,
|
||||
"experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */
|
||||
"emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */
|
||||
"skipLibCheck": true /* Skip type checking all .d.ts files. */,
|
||||
"forceConsistentCasingInFileNames": true /* Ensure that casing is correct in imports. */,
|
||||
"declaration": true
|
||||
//"declaration": true, /* Enables experimental support for emitting type metadata for decorators. */
|
||||
},
|
||||
"exclude": ["_old", "node_modules", "src/make-files", "src/skeletons", "src/tests", "src/interfaces", "src/utils"]
|
||||
"exclude": ["src/tests", "./tests"]
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user