Created
September 2, 2022 10:50
-
-
Save iainsproat/9c53349341fe7a943293b99d2f0c2c8c to your computer and use it in GitHub Desktop.
reach an http endpoint in a node container without curl
This file contains hidden or 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
require('http').get({host: '<REPLACE_ME>.<REPLACE_ME>.svc.cluster.local.', path:'/graphql', port:3000}, (resp) => { console.log(resp.statusCode); }).on("error", (err) => { console.log("error: " + err.message);}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment