...
Code Block |
---|
language | text |
---|
theme | FadeToGrey |
---|
|
git fetch && git checkout develop |
- Configure npm to connect to Search Technologies artifactory repository for local dependencies:
- Open cmd as Administrator
Code Block |
---|
language | text |
---|
theme | FadeToGrey |
---|
|
npm install npmrc
npmrc -c local
npm config set registry https://repository.searchtechnologies.com/artifactory/api/npm/npm-virtual |
Code Block |
---|
language | text |
---|
theme | FadeToGrey |
---|
|
curl -u<USERNAME>:<PASSWORD> https://repository.searchtechnologies.com/artifactory/api/npm/auth |
- Append response to: C:\Users\<USERNAME>\.npmrcs\local
- Save file
Code Block |
---|
language | text |
---|
theme | FadeToGrey |
---|
|
npm install |
...
An environment configuration will inherit the configuration present in the config/env/all.js
file and can overwrite any configuration field by redefining it on the environments file. New configuration fields be added to the environment file.
All configuration example:
Code Block |
---|
|
'use strict';
module.exports = {
app: {
title: 'Staging Repository',
description: 'Staging Repository',
keywords: 'MongoDB, Express, Node.js'
},
port: process.env.PORT || 3000,
templateEngine: 'swig',
dbConn: {
type: 'mongo',
hbase:{
server: 'hadoop-thrift-server',
port: 9090
},
mongo:{
server:'localhost',
port: 27017,
sharding: false
}
},
keyManager:{
type:'filebased',
keysNumber: 1000,
filebased:{
masterKeyLocation: 'config/MasterKey.txt'
}
},
reqBodySize: '1gb',
reprocessQueue:{
batchSize: 20,
querySize: 40,
timeout: 3000
},
clusterMode: false
}; |
Environment specific configuration (secure.js). In this example, the port and clusterMode parameter will be overridden. authList, logging, keyLocation, certLocation, caLocation and passphrase will be added to the applications configuration.
Code Block |
---|
|
'use strict';
module.exports = {
port: 44300,
authList :[
'Aspire',
'testuser'
],
logging:{
express: {
request: [
'connection.remoteAddress',
'authorizedCN'
],
response: [
]
},
transports:{
console:{
level: 'debug',
enable: false
},
file:{
level: 'info',
enable: true
}
}
},
keyLocation: 'config/sslcerts/sr_server_key.pem',
certLocation: 'config/sslcerts/sr_server_cert.crt',
caLocation: 'config/sslcerts/cacert.crt',
passphrase: '123456abC',
clusterMode: true
}; |
...