[ckan-dev] Home/landing page

Adrià Mercader adria.mercader at okfn.org
Wed Mar 27 09:53:10 UTC 2019


Hi Judith,

To your original question, the home page is rendered using these templates:

https://github.com/ckan/ckan/blob/master/ckan/templates/home/index.html
https://github.com/ckan/ckan/blob/master/ckan/templates/home/layout1.html

Now, to run in development mode you first need to install the development
requirements:

https://docs.ckan.org/en/latest/maintaining/installing/install-from-source.html#importerror-no-module-named-flask-debugtoolbar

You might need to change the path to the requirements file, and make sure
to activate the virtualenv like Sam mentioned.

The Flask Debug Toolbar was introduced in recent versions so the
documentation that you mention (2.3.x) is clearly outdated. You can check
the version CKAN is running looking at the `ckan/__init__.py` file or
visiting http://ckansite/api/action/status_show

Hope this helps,

Adrià


On Wed, 27 Mar 2019 at 09:07, Neuvonen Samuli <samuli.neuvonen at ymparisto.fi>
wrote:

> Hello,
>
>
>
> I’m not sure what’s the official way to do it, but in our environment the
> way to run CKAN in debug mode is to do it locally, on the server. So, I do
> it as follows:
>
>
>
> 1.      Log on the server (remote desktop or Putty or whatever way you do
> it).
>
> 2.      Stop Apache:
>
>
>
> apachectl stop
>
>
>
> 3.      Change parameters in the production.ini (or development.ini, if
> you use that) to something like:
>
>
>
> debug = true
>
>>
> ckan.site_url = http://127.0.0.1:5000
>
>
>
> 4.      Start locally with paster:
>
>
>
> . /usr/lib/ckan/default/bin/activate
>
> cd /usr/lib/ckan/default/src/ckan
>
> paster serve /etc/ckan/default/production.ini
>
>
>
> After this, the site can viewed locally on the server, opening a browser
> at http://127.0.0.1:5000/.
>
>
>
> When you want to return “online”, do the opposite (first killing the
> paster process).
>
>
>
> Again, I’m not sure if this is the normal way to do it, especially as our
> CKAN version is a bit of a mix. In this case I hope someone else on the
> list can provide the correct way. I would be interested to hear it as well…
>
>
>
> Hope this helps,
>
> Sam
>
>
>
>
>
> *From:* ckan-dev [mailto:ckan-dev-bounces at lists.okfn.org] *On Behalf Of *Judith
> Moran
> *Sent:* 27. maaliskuuta 2019 9:44
> *To:* CKAN Development Discussions
> *Subject:* Re: [ckan-dev] Home/landing page
>
>
>
> Hi,
>
>
>
> I changed to false and the home page fails to load.
>
>
>
> *Internal Server Error*
>
> The server encountered an internal error or misconfiguration and was
> unable to complete your request.
>
> Please contact the server administrator at root at localhost to inform them
> of the time this error occurred, and the actions you performed just before
> this error.
>
> More information about this error may be available in the server error log.
>
>
>
>
>
> Previous CKAN person has made a new theme for site and it appears that
> debug does not work with the theme??
>
>
>
> Hmm any suggestions.
>
>
>
> Jud
>
>
>
>
>
>
>
> *From:* ckan-dev [mailto:ckan-dev-bounces at lists.okfn.org] *On Behalf Of *Neuvonen
> Samuli
> *Sent:* Wednesday, 27 March 2019 3:48 PM
> *To:* CKAN Development Discussions <ckan-dev at lists.okfn.org>
> *Subject:* Re: [ckan-dev] Home/landing page
>
>
>
> Hello,
>
>
>
> Not much more than a novice myself, I found it useful to run CKAN
> indebug-mode (
> https://docs.ckan.org/en/2.8/maintaining/configuration.html?highlight=debug#debug)
> to see what templates are used in each view. See more in Customizing CKAN’s
> templates (https://docs.ckan.org/en/2.8/theming/templates.html).
>
>
>
> Also, the description of CKAN code architecture can help:
> https://docs.ckan.org/en/2.8/contributing/architecture.html
>
>
>
> Regards,
>
> Sam
>
>
>
>
>
> *From:* ckan-dev [mailto:ckan-dev-bounces at lists.okfn.org
> <ckan-dev-bounces at lists.okfn.org>] *On Behalf Of *Judith Moran
> *Sent:* 27. maaliskuuta 2019 7:12
> *To:* CKAN Development Discussions
> *Subject:* [ckan-dev] Home/landing page
>
>
>
> Hi,
>
>
>
> Totally novice to CKAN.
>
>
>
> Can someone explain how the home page is instigated in CKAN.
>
>
>
>
>
> Thx
>
>
>
>
>
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> https://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20190327/3fa291f5/attachment-0002.html>


More information about the ckan-dev mailing list