HTTP.post() to HTTPS url - how do I ignore "Error: Hostname/IP doesn't match certificate's altnames"?

So I am trying to use the HTTP.post() method that Meteor makes available to post some data to a URL that is using HTTPS.

I am getting an error as follows: Error: Hostname/IP doesn't match certificate's altnames

I am pretty sure that I am getting this error only because I am testing in a staging environment. How can I proceed around this error for staging?

Thanks,

Jon

From here: https://github.com/meteor/meteor/issues/1703 Apparently this should work:

HTTP.post(url, {
    npmRequestOptions: {
        rejectUnauthorized: false // TODO remove when deploy
    },
    timeout: 30000,
    data: xml
}

rejectUnauthorized: false should work; are you calling this on the server? npmRequestOptions is only supported server side.