Question

I want to deploy a ravendb server in production. I don't want it to be accessible by anyone, so Raven/AnonymousAccess is set to None

I want to use OAuth as authentication, but how can I now setup a new ApiKey?

I want this to be automated, so "install raven with AnonymousAccess = Admin, create apikeys manually, set AnonymousAccess to None manually" is not an option.

Is there a way in which I can either

  • Create a new ApiKey even though AnonymousAccess is set to None or
  • Create an ApiKey automatically and then change AnonymousAccess to None automatically

(and by automatically I mean: in code)

Thanks!

Was it helpful?

Solution 2

I still haven't found a way to do this properly. The way I'm currently handling it is:

  1. Deploy with Raven/AnonymousAccess set to Admin
  2. Set the ApiKeys manually
  3. Redeploy with Raven/AnonymousAccess set to None

Not the best way, but at the moment, I can't find a better way.

OTHER TIPS

You can do that by authenticating using Windows Auth then setting up the API keys.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top