commmm
parent
55a0040734
commit
b2a42533b6
35
package.json
35
package.json
|
@ -1,14 +1,7 @@
|
|||
{
|
||||
"name": "iut-project-cemal",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"name": "hapipal-boilerplate",
|
||||
"version": "3.0.0",
|
||||
"main": "lib/index.js",
|
||||
"directories": {
|
||||
"lib": "lib",
|
||||
"test": "test"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "node server",
|
||||
"test": "lab -a @hapi/code -I \"__core-js_shared__,CSS,regeneratorRuntime,core\" -L",
|
||||
|
@ -17,14 +10,7 @@
|
|||
"dependencies": {
|
||||
"@hapi/boom": "9.x.x",
|
||||
"@hapipal/haute-couture": "4.x.x",
|
||||
"joi": "17.x.x",
|
||||
"objection": "2.x.x",
|
||||
"@hapipal/schwifty": "6.x.x",
|
||||
"sqlite3": "5.0.2",
|
||||
"exiting": "6.0.1"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"knex": "0.21.x"
|
||||
"joi": "17.x.x"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@hapi/code": "8.x.x",
|
||||
|
@ -32,18 +18,17 @@
|
|||
"@hapi/eslint-plugin-hapi": "4.x.x",
|
||||
"@hapi/glue": "8.x.x",
|
||||
"@hapi/hapi": "20.x.x",
|
||||
"@hapi/hoek": "9.x.x",
|
||||
"@hapi/inert": "6.x.x",
|
||||
"@hapi/lab": "23.x.x",
|
||||
"@hapi/lab": "24.x.x",
|
||||
"@hapi/vision": "6.x.x",
|
||||
"babel-eslint": "10.x.x",
|
||||
"@hapipal/confidence": "6.x.x",
|
||||
"dotenv": "8.x.x",
|
||||
"eslint": "7.x.x",
|
||||
"hapi-swagger": "14.x.x",
|
||||
"@hapipal/hpal": "3.x.x",
|
||||
"@hapipal/hpal-debug": "2.x.x",
|
||||
"knex": "^0.21.16",
|
||||
"@hapipal/toys": "3.x.x"
|
||||
"@hapipal/toys": "3.x.x",
|
||||
"babel-eslint": "10.x.x",
|
||||
"dotenv": "8.x.x",
|
||||
"eslint": "7.x.x",
|
||||
"exiting": "6.x.x",
|
||||
"hapi-swagger": "14.x.x"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
const Dotenv = require('dotenv');
|
||||
const Confidence = require('@hapipal/confidence');
|
||||
const Toys = require('@hapipal/toys');
|
||||
const Schwifty = require('@hapipal/schwifty');
|
||||
|
||||
// Pull .env into process.env
|
||||
Dotenv.config({ path: `${__dirname}/.env` });
|
||||
|
@ -13,14 +12,14 @@ module.exports = new Confidence.Store({
|
|||
server: {
|
||||
host: 'localhost',
|
||||
port: {
|
||||
$env: 'PORT',
|
||||
$param: 'PORT',
|
||||
$coerce: 'number',
|
||||
$default: 3000
|
||||
},
|
||||
debug: {
|
||||
$filter: { $env: 'NODE_ENV' },
|
||||
$filter: 'NODE_ENV',
|
||||
$default: {
|
||||
log: ['error'],
|
||||
log: ['error', 'start'],
|
||||
request: ['error']
|
||||
},
|
||||
production: {
|
||||
|
@ -34,35 +33,9 @@ module.exports = new Confidence.Store({
|
|||
plugin: '../lib', // Main plugin
|
||||
options: {}
|
||||
},
|
||||
{
|
||||
plugin: './plugins/swagger'
|
||||
},
|
||||
{
|
||||
plugin: '@hapipal/schwifty',
|
||||
options: {
|
||||
$filter: 'NODE_ENV',
|
||||
$default: {},
|
||||
$base: {
|
||||
migrateOnStart: true,
|
||||
knex: {
|
||||
client: 'sqlite3',
|
||||
useNullAsDefault: true, // Suggested for sqlite3
|
||||
connection: {
|
||||
filename: ':memory:'
|
||||
},
|
||||
migrations: {
|
||||
stub: Schwifty.migrationsStubPath
|
||||
}
|
||||
}
|
||||
},
|
||||
production: {
|
||||
migrateOnStart: false
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
plugin: {
|
||||
$filter: { $env: 'NODE_ENV' },
|
||||
$filter: 'NODE_ENV',
|
||||
$default: '@hapipal/hpal-debug',
|
||||
production: Toys.noop
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue