How to install a local copy of www.gnome.org

This tutorial will show you how to create a local copy of the www.gnome.org (wgo) website. It basically involves two main steps: Installing WordPress, along with the GNOME Grass theme, and uploading the current existing content (posts and pages) to your local instance.

Pre-Requisites

Steps

1. Install WordPress

  • WordPress is an Open Source CMS (Content Management System). WGO runs on top of a WordPress installation.

  • Follow the steps in the "Famous 5-Minute Install" tutorial to download and set up WordPress

    • For Step 1, the download step, download WordPress and either

      • Unzip the package in /var/www/html, e.g. in directory gnome-web-www; you will later be able to view the website at http://localhost/gnome-web-www - this is the way used in the examples through the rest of the page

        cd /var/www/html
        sudo mkdir gnome-web-www
        sudo chown your-user-name gnome-web-www
        // extract files into this directory
        • If you initially extracted files in e.g. wordpress directory in your home directory, then you need to do

          cd /var/www/html
          sudo mkdir gnome-web-www
          sudo mv ~/wordpress/ html/gnome-web-www
          restorecon -v -R .
      • Or enable userdirs (How to enable Apache Userdir on Fedora), which is good for avoiding permission problems; you will later be able to view the website at http://localhost/~your-user-dir/gnome-web-www

    • For Step 2, the database creation step, you can create a database with a name "gnomewebwww", user "wordpressgnome" and password "gnomie" as following
      sudo systemctl start mariadb
      sudo mysql
      CREATE DATABASE gnomewebwww;
      GRANT ALL PRIVILEGES ON gnomewebwww.* TO "wordpressgnome"@"localhost" IDENTIFIED by "gnomie";
      FLUSH PRIVILEGES;
      • To get to the database console later, do mysql -u wordpressgnome -p gnomewebwww

    • For Step 3, the config update step
      cd /var/www/html/gnome-web-www
      mv wp-config-sample.php wp-config.php
      // update name, user, and password in wp-config.php as selected in Step 2
    • Then start httpd with sudo systemctl start httpd and set your WordPress instance up by visiting http://localhost/gnome-web-www/wp-admin/install.php

2. Install the GNOME Grass theme

  • In /var/www/html/gnome-web-www/wp-content/themes, run git clone git://git.gnome.org/gnome-web-www or, if you have a GNOME Git account, git clone ssh://your-git-username@git.gnome.org/git/gnome-web-www

    • If you ran the first command, but later want to set up access with your GNOME Git account, edit /var/www/html/gnome-web-www/wp-content/themes/gnome-web-www/.git/config and update url to ssh://your-git-username@git.gnome.org/git/gnome-web-www

3. Import content from WGO

  • Download the WGO content XML file

  • Install the WordPress Importer plugin.

  • Import the XML file
  • Set Home to the frontpage in Settings > Reading > Homepage.

  • Troubleshooting:

    • In case the XML file extends the file size limit,
      1. In most of the cases, it works by just compressing the XML file and importing;
      2. If that does not work, edit the settings for maximum upload size in /etc/php/php.ini ; set upload_max_filesize to a value bigger than the size of the XML file. - 1, 2

4. View the pages

  • You can view the static pages by, for example, visiting http://localhost/gnome-web-www/wp-content/themes/gnome-web-www/theme/opw

GnomeWeb/Tutorials/LocalWGO (last edited 2015-01-24 23:27:07 by MarinaZ)