ckan-docker icon indicating copy to clipboard operation
ckan-docker copied to clipboard

Site broken when ckan.root_path is set

Open joaotonelli opened this issue 1 year ago • 3 comments

Hi,

I need to set the ckan.root_path in the ckan.ini for a project that I work on. When I do so, the site breaks. It seems to be something related to webassets and template locations.

Repro steps:

  • Just set it in the .env file: CKAN__ROOT_PATH=/myroot

Here follows some printscreens:

image

image

joaotonelli avatar Apr 12 '24 13:04 joaotonelli

Hum, is that CKAN__ROOT_PATH variable documented somewhere?

Chealer avatar Apr 12 '24 13:04 Chealer

Absolutely. Here follows the CKAN official doc page: https://docs.ckan.org/en/2.10/maintaining/configuration.html#ckan-root-path

joaotonelli avatar Apr 12 '24 18:04 joaotonelli

Hi,

I have finally managed to fix this problem. Actually, I had to configure the nginx container to redirect the requests accordingly (using the /myroot/ prefix).

I don’t know whether it is the best solution, but it seems to be working fine now.

joaotonelli avatar Apr 12 '24 21:04 joaotonelli