Created
May 20, 2016 05:57
-
-
Save hyperh/cd3bbfb5944e6c70381c2ab1d2c7fe17 to your computer and use it in GitHub Desktop.
apnagent setup
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
import apnagent from 'apnagent'; | |
let agent = new apnagent.Agent(); | |
agent | |
.set('cert', Assets.getText('cert.pem')) | |
.set('key', Assets.getText('key.pem')) | |
.enable('sandbox') | |
.connect(function (err) { | |
if (err) { | |
console.log('agent connect error', err) | |
throw err; | |
} | |
}); | |
export default agent; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment