-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d846cd2
commit 8437cdd
Showing
2 changed files
with
65 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,44 @@ | ||
export const ORAKL_NETWORK_API_URL = | ||
process.env.ORAKL_NETWORK_API_URL || 'http://localhost:3000/api/v1' | ||
const production = process.env.NODE_ENV == 'production' | ||
const default_api_url = production | ||
? 'http://api.orakl.svc.cluster.local' | ||
: 'http://localhost:3000/api/v1' | ||
const default_delegator_url = production | ||
? 'http://delegator.orakl.svc.cluster.local' | ||
: 'http://localhost:3002/api/v1' | ||
|
||
const default_fetcher_host = production | ||
? 'http://fetcher.orakl.svc.cluster.local' | ||
: 'http://localhost' | ||
const default_fetcher_port = production ? '4040' : '3001' | ||
|
||
const default_listener_host = production | ||
? 'http://aggregator-listener.orakl.svc.cluster.local' | ||
: 'http://localhost' | ||
const default_listener_port = production ? '4000' : '4000' | ||
|
||
const default_worker_host = production | ||
? 'http://aggregator-worker.orakl.svc.cluster.local' | ||
: 'http://localhost' | ||
const default_worker_port = production ? '5000' : '5001' | ||
|
||
const default_reporter_host = production | ||
? 'http://aggregator-reporter.orakl.svc.cluster.local' | ||
: 'http://localhost' | ||
const default_reporter_port = production ? '6000' : '6000' | ||
|
||
export const ORAKL_NETWORK_API_URL = process.env.ORAKL_NETWORK_API_URL || default_api_url | ||
export const ORAKL_NETWORK_DELEGATOR_URL = | ||
process.env.ORAKL_NETWORK_DELEGATOR_URL || 'http://localhost:3002/api/v1' | ||
process.env.ORAKL_NETWORK_DELEGATOR_URL || default_delegator_url | ||
|
||
export const FETCHER_HOST = 'http://localhost' | ||
export const FETCHER_PORT = 3001 | ||
export const FETCHER_HOST = process.env.FETCHER_HOST || default_fetcher_host | ||
export const FETCHER_PORT = process.env.FETCHER_PORT || default_fetcher_port | ||
export const FETCHER_API_VERSION = '/api/v1' | ||
|
||
export const LISTENER_SERVICE_HOST = process.env.LISTENER_SERVICE_HOST || 'http://localhost' | ||
export const LISTENER_SERVICE_PORT = process.env.LISTENER_SERVICE_PORT || 4000 | ||
export const LISTENER_SERVICE_HOST = process.env.LISTENER_SERVICE_HOST || default_listener_host | ||
export const LISTENER_SERVICE_PORT = process.env.LISTENER_SERVICE_PORT || default_listener_port | ||
|
||
export const WORKER_SERVICE_HOST = process.env.WORKER_SERVICE_HOST || 'http://localhost' | ||
export const WORKER_SERVICE_PORT = process.env.WORKER_SERVICE_PORT || 5001 | ||
export const WORKER_SERVICE_HOST = process.env.WORKER_SERVICE_HOST || default_worker_host | ||
export const WORKER_SERVICE_PORT = process.env.WORKER_SERVICE_PORT || default_worker_port | ||
|
||
export const REPORTER_SERVICE_HOST = process.env.REPORTER_SERVICE_HOST || 'http://localhost' | ||
export const REPORTER_SERVICE_PORT = process.env.REPORTER_SERVICE_PORT || 6000 | ||
export const REPORTER_SERVICE_HOST = process.env.REPORTER_SERVICE_HOST || default_reporter_host | ||
export const REPORTER_SERVICE_PORT = process.env.REPORTER_SERVICE_PORT || default_reporter_port |