Default Port of 5984 Breaking Connections to Cloudant over HTTPS #29

Open
mhemesath opened this Issue Jun 10, 2011 · 2 comments

Comments

Projects
None yet
2 participants

I'm trying to setup an app on Heroku. Heroku provides the URL to the your couch instance through an environment variable. So connecting to the database would be achieved like this:

var CouchClient = require('couch-client');
var client = new CouchClient(process.env.CLOUDANT_URL + "/myDocument")

The resulting URL is over HTTPs, however, because the port 5984 is defaulted, the connection never works.

See: http://support.cloudant.com/kb/faqs/does-cloudant-support-ssl
And: http://devcenter.heroku.com/articles/cloudant

hdachev commented Jun 13, 2011

Try setting CLOUDANT_URL to "https://username:password@host:443"

Yeah, I have that coded in for now and it seems to work. It's a bit weird though, as a working URL is supplied by Heroku on

process.env.CLOUDANT_URL

and I have to end up doing

 process.env.CLOUDANT_URL + ":443/myDocument"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment