Couchdb sync access with userid and password

后端 未结 1 710
难免孤独
难免孤独 2020-12-19 21:47

I have a couchdb running on a virtual linux machine. This db has cors enabled and setup. I have added an admin user and password to the db. I also have require_valid_user s

相关标签:
1条回答
  • 2020-12-19 22:34

    I had the same problem with the exact same error message trying to sync to a couchDB on cloudant.com. For me, the solution was to use https:// instead of http:// in the URL of the remote server. The format of the URL should be:

    https://<api_key>:<key_passwd>@<username>.cloudant.com/<db_name>

    So although I do not have a locally installed DB to test this, I suspect your error stems from the fact that couch redirects the request to a secure connection when you provide your credentials (scenario 1). While in scenario 2 no redirect occurs.

    0 讨论(0)
提交回复
热议问题