CEO
I was following the tutorial here.
When ssh’ing into the machine, i can access both Kibana and Elasticsearch via localhost mappings:
If i run, form the SSH terminal:
Curl -XGET localhost:5601/status , it returns the kibana site in all its html glory.
If i run, from the SSH terminal:
Curl -XGET localhost:9200 , it returns the default JSON object from elasticsearch telling me that it is running.
This means that both services are running OK, and both services are in fact mapped to their respective ports and accessible over localhost.
I would like to be able to access Elasticsearch from my API, and Kibana from my droplets IP address.
I then set up an NGINX config to map any incoming call on :80 to :5601 , so that i can access Kibana on my droplets ip. This is my server config:
server {
listen 80;
server_name localhost;
#auth_basic "Restricted Access";
#auth_basic_user_file /etc/nginx/htpasswd.users;
location / {
proxy_pass http://localhost:5601;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}
Now, if i run Curl -XGET localhost:80/status i do get the kibana site as above in html written out.
But here is the problem, i still cant access it on mydropletip:5601/status OR mydropletip:80/status from outside localhost on the machine.
My UFW is set up to Nginx Full:
To Action From
-- ------ ----
OpenSSH ALLOW Anywhere
9200 ALLOW My API's IP Address
Nginx Full ALLOW Anywhere
OpenSSH (v6) ALLOW Anywhere (v6)
Nginx Full (v6) ALLOW Anywhere (v6)
Why is it that i still cant access neither Elasticsearch nor Kibana on my droplets IP address when it seems the network config is set up to allow this?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there,
In case that you want to be able to access mydropletip:5601/status you would need to allow that port with:
ufw allow 5601
Regarding the reverse proxy at mydropletip:80/status this should indeed work, do you get any errors when you try to access it? I could suggest checking your Nginx logs for some more information:
tail -100 /var/log/nginx/error.log
Regards,
Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.