0

I'm trying add Custom Authentication. I use 2 instances of Sync-Gateway behind an Nginx. So how can we manage Session with 2 instances of Sync-Gateway?

The custom authentication is achieved by calling the "//_session" endpoint. This then returns a cookie that logs me in for the first Sync-Gateway. If I now want to synchronize the second Sync-Gateway too, I make a call to "//_session" which overrides the first cookie.

Is there any way to create a global Session?

youssef Liouene
  • 873
  • 6
  • 15
  • 28
  • This question is also being discussed on the Couchbase Forum. Cross-reference, for visitors from the future: https://forums.couchbase.com/t/custom-authentication-with-2-sync-gateway/29762 – dnault Mar 12 '21 at 00:41

1 Answers1

1

Please see this answer, from bbrks, here: https://forums.couchbase.com/t/custom-authentication-with-2-sync-gateway/29762 :

If you’re using 2 separate CB buckets/SG databases, they’re completely independent systems and user-information is not shared between them.

G. Blake Meike
  • 6,615
  • 3
  • 24
  • 40