doc/book/en/intro/tutorial/blog-in-five-minutes.rst
author Sylvain Thénault <sylvain.thenault@logilab.fr>
Tue, 26 Jan 2010 16:47:45 +0100
changeset 4374 ff3efacfea42
parent 4143 e6d936eef7aa
child 4431 e597e0ca67cd
permissions -rw-r--r--
by default use new jquery widgets for Time/Date/DateTime fields
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
     1
.. -*- coding: utf-8 -*-
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
     2
2175
16d3c37c5d28 [doc] improvements
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 2174
diff changeset
     3
.. _BlogFiveMinutes:
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
     4
2175
16d3c37c5d28 [doc] improvements
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 2174
diff changeset
     5
Get a blog running in five minutes!
16d3c37c5d28 [doc] improvements
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 2174
diff changeset
     6
-----------------------------------
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
     7
2175
16d3c37c5d28 [doc] improvements
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 2174
diff changeset
     8
First install the following packages (:ref:`DebianInstallation`)::
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
     9
1441
8e7a99cbce3c [doc] Short down the `blog running in less ten nimutes` section to remove duplicated content.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents: 1439
diff changeset
    10
    cubicweb, cubicweb-dev, cubicweb-blog
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    11
2175
16d3c37c5d28 [doc] improvements
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 2174
diff changeset
    12
Then create and initialize your instance::
2172
cf8f9180e63e delete-trailing-whitespace
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 1715
diff changeset
    13
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    14
    cubicweb-ctl create blog myblog
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    15
2175
16d3c37c5d28 [doc] improvements
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents: 2174
diff changeset
    16
And start it::
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    17
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    18
    cubicweb-ctl start -D myblog
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    19
4143
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    20
The -D option is the debugging mode of cubicweb, removing it will lauch the instance in the background.
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    21
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    22
Permission
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    23
~~~~~~~~~~
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    24
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    25
This command assumes that you have root access to the /etc/ path. In order to initialize your instance as a `user` (from scratch), please check your current PYTHONPATH then create the ~/etc/cubicweb.d directory.
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    26
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    27
Instance parameters
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    28
~~~~~~~~~~~~~~~~~~~
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    29
4143
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    30
If the database installation failed, you'd like to change some instance parameters, for example, the database host or the user name. These informations can be edited in the `source` file located in the /etc/cubicweb.d/myblog directory.
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    31
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    32
Then relaunch the database creation:
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    33
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    34
     cubicweb-ctl db-create myblog
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    35
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    36
Other paramaters, like web server or emails parameters, can be modified in the `all-in-one.conf` file.
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    37
e6d936eef7aa [mq]: doc
Charles Hébert
parents: 2175
diff changeset
    38
This is it. Your blog is running. Visit http://localhost:8080 and enjoy it! This blog is fully functionnal. The next section section will present the way to develop new cubes and customizing the look of your instance.
1210
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    39
47a3eb4bbe66 [doc] Adds a short section on how to launch a blog based on the packages cubicweb and cubicweb-blog.
Sandrine Ribeau <sandrine.ribeau@logilab.fr>
parents:
diff changeset
    40