Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,18 @@ There are many ways to get involved:
3. Clone [Apinf](https://github.com/apinf/api-umbrella-dashboard)
4. Create [`settings.json`](#Settings.json)
5. Type `meteor --settings /path/to/settings.json` in the project directory

# Settings.json

Your `settings.json` file should have the following structure:

```
{
"apinf": {
"host": "https://example.com/"
},
"api_umbrella": {
"host": "https://example.com/"
"api_key": "xxx",
"auth_token": "xxx",
"base_url": "https://example.com/api-umbrella/"
Expand Down
6 changes: 3 additions & 3 deletions server/methods/status.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Meteor.methods({
try{

// initial host for apinf
var apinfHost = "https://apinf.com";
var apinfHost = Meteor.settings.apinf.host;

// response object from apinf GET request
var apinfResponse = Meteor.http.call("GET", apinfHost);
Expand Down Expand Up @@ -49,7 +49,7 @@ Meteor.methods({
try{

// initial host for API umbrella
var apiUmbrellaHost = "https://umbrella.apinf.io/";
var apiUmbrellaHost = Meteor.settings.api_umbrella.host;

// response object from API Umbrella GET request
var apiUmbrellaResponse = Meteor.http.call("GET", apiUmbrellaHost);
Expand Down Expand Up @@ -87,7 +87,7 @@ Meteor.methods({

try{
// initial host for elasticsearch instance
var elasticsearchInstance = "http://apinf.com:14002/";
var elasticsearchInstance = Meteor.settings.elasticsearch.host;

// response object from elasticsearch GET request
var elasticsearchResponse = Meteor.http.call("GET", elasticsearchInstance);
Expand Down