forked from mirrors/Scribe.js
Updating examples to use higher port values
This commit is contained in:
parent
3766f58d5f
commit
28b9309ccd
2 changed files with 8 additions and 6 deletions
|
@ -5,7 +5,7 @@ import Scribe from '../index.js'
|
|||
import * as JSON2 from '../libs/JSON2'
|
||||
|
||||
const port = 4005;
|
||||
const socketPort = 4000;
|
||||
const socketPort = 50000;
|
||||
const cpus = 4;
|
||||
|
||||
if (cluster.isMaster) {
|
||||
|
@ -18,7 +18,7 @@ if (cluster.isMaster) {
|
|||
mongoUri: 'mongodb://localhost/scribe',
|
||||
publicUri: 'http://localhost',
|
||||
basePath: 'scribe/',
|
||||
socketPort: 4000 + cluster.worker.id - 1,
|
||||
socketPort: socketPort + cluster.worker.id - 1, // assign a port to a worker worker
|
||||
web: {
|
||||
router: {
|
||||
username: 'build',
|
||||
|
@ -31,7 +31,7 @@ if (cluster.isMaster) {
|
|||
useSession: true
|
||||
},
|
||||
client: {
|
||||
port: 4005,
|
||||
port: port,
|
||||
socketPorts: [socketPort, socketPort + 1, socketPort + 2, socketPort + 3],
|
||||
exposed: {
|
||||
all: {label: 'all', query: {expose: {$exists: true}}},
|
||||
|
|
|
@ -3,12 +3,14 @@ import Scribe from '../index.js'
|
|||
import * as JSON2 from '../libs/JSON2'
|
||||
|
||||
const port = 4005;
|
||||
const socketPort = 50000;
|
||||
|
||||
const console = new Scribe(process.pid, {
|
||||
name: 'Scribe',
|
||||
mongoUri: 'mongodb://localhost/scribe',
|
||||
publicUri: 'http://localhost',
|
||||
basePath: 'scribe/',
|
||||
socketPort: 4000,
|
||||
socketPort: socketPort,
|
||||
web: {
|
||||
router: {
|
||||
username: 'build',
|
||||
|
@ -19,8 +21,8 @@ const console = new Scribe(process.pid, {
|
|||
useSession: true
|
||||
},
|
||||
client: {
|
||||
port: 4005,
|
||||
socketPorts: [4000],
|
||||
port: port,
|
||||
socketPorts: [socketPort],
|
||||
exposed: {
|
||||
all: {label: 'all', query: {expose: {$exists: true}}},
|
||||
error: {label: 'error', query: {expose: 'error'}},
|
||||
|
|
Loading…
Add table
Reference in a new issue