demo/demo doesn't work ... redirects to /login/
When I try accessing the :16649 Iris login, it just redirects me back to login every time. Here is the log dump:
[2018-11-14 22:36:48 +0000] [2051] [INFO] iris.ui Successful login for demo
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "POST /login/?next=%2Fincidents HTTP/1.1" 302 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /incidents HTTP/1.1" 302 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /login/?next=%2Fincidents HTTP/1.1" 200 1840 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/bundles/iris.js?e9f6526e HTTP/1.1" 200 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/bundles/libs.css?126f96b3 HTTP/1.1" 200 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/bundles/bootstrap.libs.js?b9542e11 HTTP/1.1" 200 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/bundles/jquery.libs.js?0c5aeb77 HTTP/1.1" 200 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/bundles/iris.css?df336c74 HTTP/1.1" 200 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/images/iris.png HTTP/1.1" 200 0 "http://x.x.x.x:16649/login/?next=%2Fincidents" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"
x.x.x.x - - [14/Nov/2018:22:36:48 +0000] "GET /static/images/iris.png?v=2 HTTP/1.1" 200 0 "-" "Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0"```
You can see it successfully logs me in on this line: [2018-11-14 22:36:48 +0000] [2051] [INFO] iris.ui Successful login for demo
In config.yaml, set server settings:
server:
host: 0.0.0.0
port: 16649
disable_auth: False # allow logins by existing users, but without checking credentials
allow_http: True # seession cookies marked secure=False if allow_http enabled. Disable in production
local_api_url: http://localhost:16649
The reason you see this is because we use cookies for auth, and you're likely currently hosting Iris via http. We set secure=True on the cookie, so it is only passed on https requests unless explicitly enabled with allow_http.
Hello there, we're trying the solution with the docker-compose option and we can't seem to log in to the demo. The frontend is up, but any user/password combination gives a 404 error.
I'm using the exact same settings dwan159 posted. The documentation on this is scarse at best... should I be using a user from an integrated LDAP or the admin tool to log in?
You can use either. The admin tool is likely easier to set up than LDAP. We suggest demo/demo since the dummy data includes the demo user by default. Check the user table in the DB, and use any username that appears there.
I hit the same issue. The problem I had was revealed by the nginx and uwsgi logs in the iris container. If you look at cat var/log/{nginx,uwsgi}/*.log during the login you'll see the problem. In my case it was uwsgi workers silently segfaulting (and nginx returning a 404 since a uwsgi worker prematurely closed the connection), which was caused by a dependency mismatch: bumping greenlet to a compatible version fixed the issue for me.