Skip to content
This repository has been archived by the owner. It is now read-only.

Allow environment to override http/https for apis #44

Merged
merged 1 commit into from Jul 5, 2017

Conversation

Projects
None yet
2 participants
@c-w
Copy link
Member

commented Jul 5, 2017

As per standup today: environment variables should be able to override whether we talk to services via http or https.

@jcjimenez
Copy link
Contributor

left a comment

LGTM

@@ -4,10 +4,10 @@ const Promise = require('promise');
const request = require('request');

const accessToken = process.env.FACEBOOK_AUTH_TOKEN;
const apiHost = process.env.FACEBOOK_API_HOST || 'graph.facebook.com';
const apiHost = process.env.FACEBOOK_API_HOST || 'https://graph.facebook.com';

This comment has been minimized.

Copy link
@jcjimenez

jcjimenez Jul 5, 2017

Contributor

The host part in the variable name seems misleading to me; may I suggest 'const baseUrl' maybe as a followup PR at some point?

This comment has been minimized.

Copy link
@c-w

c-w Jul 5, 2017

Author Member

Sounds good. Will make a follow up PR.

@c-w c-w merged commit 2aaede6 into master Jul 5, 2017

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@c-w c-w deleted the protocol-from-env branch Jul 5, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.