I install CKAN 2.9 in a local Debian Buster VM, by following the instructions on how to install from source and deployment.
I am using NGINX and have the proxy_pass
in place and nginx and ckan.root_path = /sfb1153/ckan
in ckan.ini. All runs weel
However when I try to login at http://192.168.60.103/sfb1153/ckan/user/login, after submitting the form, the path that CKAN redirects to is missing the root_path (/sfb1153/ckan
) and leads me to a 404.
Here is the nginx access log:
192.168.60.1 - - [17/Oct/2020:13:11:27 +0000] "POST /sfb1153/ckan/login_generic?came_from=/sfb1153/ckan/user/logged_in HTTP/1.1" 302 379 "http://192.168.60.103/sfb1153/ckan/user/login" "Mozilla/5.0 (X11; Linux x86_64; rv:81.0) Gecko/20100101 Firefox/81.0"
192.168.60.1 - - [17/Oct/2020:13:11:27 +0000] "GET /user/logged_in?came_from=%2Fsfb1153%2Fckan%2Fuser%2Flogged_in&__logins=0 HTTP/1.1" 404 143 "http://192.168.60.103/sfb1153/ckan/user/login" "Mozilla/5.0 (X11; Linux x86_64; rv:81.0) Gecko/20100101 Firefox/81.0"
Notice that:
- POST goes to:
/sfb1153/ckan/login_generic
which is correct - response GET goes to:
/user/logged_in
which is missing the root_path and as a result returns a 404
Any ideas how to address this issue?
2
Answers
The same value as the
ckan.root_path
in ckan.ini needs to be added topost_login_url
andpost_logout_url
variables of /etc/ckan/default/who.iniYou need to update the value of the site url in the .env file or the configuration file with the ip address.