Elastic agent fleet enrollment with Nginx authentication help

I setup an ELK stack server along with Nginx. I am trying to make use of the Elastic Agent Fleet enrollment so that I can utilize the endpoint security and do some digging. However, I noticed that if I try to enroll an agent, I get a message "401 Authorization Required" - which I assume is Nginx blocking the request since I have both Kibana and ES behind Nginx. I can login just fine if I visit the url, but I am not sure what to do when it comes to enrolling an agent when the stack is behind Nginx. Any help or advice would be much appreciated, still new to this!

Welcome to our community! :smiley:

What's the reason for using nginx in front of the services?

Honestly, I was following a guide and it mentioned to use it. I was thinking about removing or disabling Nginx but I couldn't seem to figure out how to revert and not use Nginx anymore. I wanted to just stay using the xpack security but I can't seem to get Nginx turned off successfully to revert back. So I suppose help with either would be great!

If you've got Security enabled you should be good, otherwise it just adds a layer of complexity you may not need.

That's what I figured, how would I properly discontinue use of Nginx from the stack then?

I'm not sure how you set it all up, but I'd just point the agent directly to Elasticsearch and Kibana and then remove nginx.

Thanks for the help, got it figured out! :grinning:

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.