In the following, I will consider you already installed apache and PHP module like I explained in this previous article.

Install the required packages

As root, install the required packages using the command:

apt-get install postgresql php5-pgsql php5-gd wget

Then, restart the apache server with the command:

/etc/init.d/apache2 restart

Database setup

We need to create a new database for the blog. In the following we will name the database as blog and the user as dotclear.

Still as root, change the current user as postgres with the command:

su - postgres

Create the new database with the command:

psql -c "create database blog;"

Create the new user for the newly created database:

psql -d blog -c "create user dotclear with password 'password';"

You may choose the password you want for the user. Simply change the password value to the password you want.

Finally, give the correct rights to the user :

psql -d blog -c "grant all on database blog to dotclear;"

The database is now ready for the Dotclear setup.

Web directory setup

Not much is necessary for the Dotclear system to be working. You basically need an empty web directory, which could be a user's public_html directory or one of its subdirectories, or a subdirectory of the /var/www directory. In this latter case, ensure the the www-data group has write access to the directory, otherwise Apache will not be able to create files in the directory.

Dotclear installation

This is a quite straightforward process. As your normal user (if you want the website to be in one user's public_html subdirectory), or as root (if the website is in some /var/www subdirectory), switch to the web directory where you want the blog to be in (use the cd command for that purpose).

Fetch the Dotclear installation script with the command:

wget http://download.dotclear.net/loader/dotclear2-loader.php

Now the rest of the setup can be done from your web browser. Simply set the browser URL to the destination URL of the blog. You normally will be able to see the dotclear2-loader.php file. Run it by clicking on its file name.

You will be asked to choose the final URL of the blog. You may set it as the same as the current directory, or you can choose to create a subdirectory. Click the "Retrieve and Unzip" button. A congratulations message should appear if everything went fine. Click the "Install Now" button.

You are now asked some database access parameters. Enter the following values:

  • Database type: PostgreSQL
  • Database hostname: localhost
  • Database name: blog
  • Database user: dotclear
  • Database password: the password you set before
  • Database table prefix: keep the default value

If everything went fine, you will be asked basic configuration information for the blog, such as a user name and a password to be able to get into the blog administration panel.

Conclusion

The rest of the blog usage is rather straightforward. Follow the menus, and you will soon be able to post your first article. Have fun ! :)