-
Notifications
You must be signed in to change notification settings - Fork 315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to put authentication to mist.io panel? #517
Comments
Hi silasrm, when we initially added docker support, the docker API was exposed without any authentication, so if you wanted to remotely communicate with a docker server through the API you had to use a proxy to encrypt the traffic, otherwise it would be completely insecure. On that article we have used the example of setting nginx on the docker server, starting docker to listen on tcp localhost 4243, and proxying it's traffic through nginx. So the client would end up communicating with the docker server through basic auth added by nginx. If you want to use this setup, the basic auth config should be setup on an nginx's conf file, example /etc/nginx/sites-enabled/default, inside the server section. However, the latest versions of Docker now support tls authentication using certs, which I highly recommend. If you want to use tls authentication with mist.io have a look on the docker's page and on mist.io docs https://docs.docker.com/articles/https/ Regards, |
Hi @mgogoulos, Thank you to reply. But, how I can add auth to access my mist.io panel? I'm access the mist.io panel using IP/domain with port 8000. Thk's |
In order to add basic auth to mist.io panel, you can setup nginx to proxypass port 8000 (where mist.io listens) to port 80 and add the basic auth, so you can access mist.io on port 80 of the server. On my Ubuntu system this is what I did:
and restart nginx root@user:/home/# /etc/init.d/nginx restart
I add a user/password So I now open the browser on |
Hi @mgogoulos, In my server, I wont put the mist on the root of the webserver, then I'm use this config:
But, when I access http://domain.com/mist/ return: 404. Got lost in the clouds. Any idea to solve this? This is my first contact to nginx :( *I managed to put the docker authenticating via TLS. :D |
I think it has to be on the top level (/). If you have domain.com on this server and you cannot put mist.io on the top level, you can create another dns name for the mist host (or set an alias on /etc/hosts). For example I set an entry on /etc/hosts for misthost.com and then set mist.io for this servername, so it is on the top level (/). server { Hope it helps |
@mgogoulos Dude, many thank's to help me. This work now! |
Very glad to read this! |
Hi,
I'm following this article, but I can't do mist.io running over http basic auth.
Where is the file I need to put the auth basic config?
Thank's!
The text was updated successfully, but these errors were encountered: