Skip to content

Commit

Permalink
test custom configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
baelter committed Nov 18, 2013
1 parent be7cfe5 commit 86778d8
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 15 deletions.
31 changes: 16 additions & 15 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,21 +35,22 @@ module.exports = function(grunt) {
}
},
custom_options: {
options: {
simulator: {
port: 6001,
rootPath: './mockmock',
useRootRelativePath: false
},
proxy: {
port : 8001,
pathnameOnly : false,
router : {
'/hoo' : '127.0.0.1:' + 6001,
'' : '127.0.0.1:' + 9001
}
}
}
options: {
simulator: {
port: 9005,
rootPath: './mocked-rest-api',
useRootRelativePath: true
},
proxy: {
port: 8001,
router : {
'/public-rest' : '127.0.0.1:' + 9005,
'/secure-rest' : '127.0.0.1:' + 9005,
'/public' : '127.0.0.1:9001',
'' : '127.0.0.1:9001'
}
}
}
}
},

Expand Down
1 change: 1 addition & 0 deletions tasks/rsimulatorjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ module.exports = function(grunt) {
}
}
};
grunt.verbose.writeln('Grunt-rsimulatorjs options: ', JSON.stringify(options));
rsimulatorjsServer(serverOptions);
grunt.log.ok('Started rsimulator on ' + options.simulator.port + ' with proxy on ' + options.proxy.port + ' with the following routes:');
for(route in options.proxy.router) {
Expand Down

0 comments on commit 86778d8

Please sign in to comment.