Hi, I want that elasticsearch of 8.15.0 should connect with kibana 8.15.0 with basic authentication but kibana is giving error i.e not server yet.But it is running without basic authentication.My docker-compose file is below which is running
without security:
When I ran your SECOND docker-compose file, i saw some authentication issues between kibana and elasticsearch. I think there's aat least two problems for your kibana settings:
Instead of ELASTIC_USERNAME and ELASTIC_PASSWORD , you could try ELASTICSEARCH_USERNAME and ELASTICSEARCH_PASSWORD. And also, I don't think you are allowed to use the elastic username (a super user) to connect to kibana for security reasons. So you might need to use the username kibana_system.
Also maybe just start from David Pilato's suggestion instead
Then you need to create a password for the kibana_system user. Do this:
# enter the elasticsearch container
docker exec -it elasticsearch bash
# reset the kibana_system password to what is specified in the docker-compose.yml file, which in this case is password
/usr/share/elasticsearch/bin/elasticsearch-reset-password -i -u kibana_system
# exit the container
exit;
# restart the kibana container
docker restart kibana
And now kibana is up for me.
However it is still best that you follow the official guides and use the initial code offered by elasticsearch team as your starting point:
I followed your suggestion and ran the command, but logging in with the kibana_system username didn’t work. Instead, I had to use the elastic username to successfully log in. I ran the ./elasticsearch-setup-passwords interactive command in /usr/share/elasticsearch/bin, set the passwords, and was able to access the Kibana dashboard using the elastic account. However, this solution isn't suitable for deployment on the server, as manually changing passwords inside the container isn't a best practice.
Our main concern is that we want to use a single image for both production and non-production environments. Since Elasticsearch will be running on ECS and requires password setup within a running container, the current approach would force us to build an image and push it to ECR on AWS. Managing two separate images for production and non-production isn’t ideal, so we’re aiming to have one unified image for both environments.
That is correct, kibana_system user is for the kibana to elastic integration. You shoudl consider seting up new accounts for actual users to login with.
If you try the official documentation, you will see that "setup containers" are used to do all the provisioning, account setup, TLS cert generation etc...
I will message you directly to your inbox with additional supporting material, so check your DM
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.