User:Djgreen/MediaWiki: Engr Installation

From WolfTech
< User:Djgreen
Revision as of 16:04, 11 October 2006 by Djgreen (talk | contribs)
Jump to navigation Jump to search

Installing 1.6.7

  1. Unpack the files into the intended directory.
  2. Create a database called mediawiki_<nameofsite>, and a corresponding useraccount
    • User account needs create, select, insert, update, delete, lock tables on the DB.
  3. Autoinstaller isn't going to work, so don't even bother.
  4. Use tables.sql in the maintenance folder to create the initial database table structures.
    • Be sure to remove all references to /*$wgDBprefix*/ within the file before trying to run it.
  5. Create your AdminSettings.php from AdminSettings.sample
  6. Create your LocalSettings.php file (use template below -- be sure to adjust for the site)
<?php

# This file was automatically generated by the MediaWiki installer.
# If you make manual changes, please keep track in case you need to # recreate them later.

$IP = ".";
require_once( "includes/DefaultSettings.php" );

if ( $wgCommandLineMode ) {
         if ( isset( $_SERVER ) && array_key_exists ( 'REQUEST_METHOD', $_SERVER ) ) {
                 die( "This script must be run from the command line \n" );
         }
} elseif ( empty( $wgNoOutputBuffer ) ) {
         ## Compress output if the browser supports it
         if( !ini_get( 'zlib.output_compression' ) ) @ob_start ( 'ob_gzhandler' ); }

$wgSitename         = "ECE ASIC";

$wgScriptPath       = "/asic/wiki";
$wgScript           = "{$wgScriptPath}/index.php";
$wgRedirectScript   = "{$wgScriptPath}/redirect.php";
$wgArticlePath      = "{$wgScriptPath}/index/$1";

$wgStylePath        = "{$wgScriptPath}/skins";
$wgStyleDirectory   = "{$IP}/skins";

$wgLogo             = "{$wgStylePath}/common/images/mediawiki.png";

$wgUploadPath       = "{$wgScriptPath}/files-wiki";
$wgUploadDirectory  = "{$IP}/files-wiki";
$wgVerifyMimeType = false;

$wgEnableEmail = true;
$wgEnableUserEmail = true;
$wgShowIPinHeader = false; # For non-logged in users

$wgEmergencyContact = "ecehelp@ncsu.edu";
$wgPasswordSender   = "ecehelp@ncsu.edu";

## For a detailed description of the following switches see 
## http://meta.wikimedia.org/Enotif and http://meta.wikimedia.org/ Eauthent 
## There are many more options for fine tuning available see 
## /includes/DefaultSettings.php 
## UPO means: this is also a user preference option $wgEnotifUserTalk = true; 
# UPO $wgEnotifWatchlist = true; 
# UPO $wgEmailAuthentication = true;

$wgDBserver         = "";
$wgDBname           = "";
$wgDBuser           = "";
$wgDBpassword       = "";
$wgDBprefix         = "";

# If you're on MySQL 3.x, this next line must be FALSE:
$wgDBmysql4 = true;

# Experimental charset support for MySQL 4.1/5.0.
$wgDBmysql5 = false;

## Shared memory settings
$wgMainCacheType = CACHE_NONE;
$wgMemCachedServers = array();

## To enable image uploads, make sure the 'images' directory ## is writable, then uncomment this:
$wgEnableUploads                = true;
# taken from the webpage
$wgFileExtensions = array( 'png', 'jpg', 'jpeg', 'ogg','xls','ppt','pdf','eps','gif' );
$wgUseImageResize               = true;
# $wgUseImageMagick = true;
# $wgImageMagickConvertCommand = "/usr/bin/convert";

## If you want to use image uploads under safe mode, 
## create the directories images/archive, images/thumb and 
## images/temp, and make them all writable. Then uncomment 
## this, if it's not already uncommented:
# $wgHashedUploadDirectory = false;

## If you have the appropriate support software installed 
## you can enable inline LaTeX equations:
# $wgUseTeX                     = true;
$wgMathPath         = "{$wgUploadPath}/math";
$wgMathDirectory    = "{$wgUploadDirectory}/math";
$wgTmpDirectory     = "{$wgUploadDirectory}/tmp";

$wgLocalInterwiki   = $wgSitename;

$wgLanguageCode = "en";

#$wgProxyKey = "[EDITED]";

## Default skin: you can change the default skin. Use the internal symbolic ## names, ie 'standard', 'nostalgia', 'cologneblue', 'monobook':
$wgDefaultSkin = 'monobook';

$wgDiff3 = "/usr/bin/diff3";

# server
$wgServer = 'http://www.wolftech.ncsu.edu';

# This replaces wgWhitelistAccount and wgWhitelistEdit 
## The following line should be commented, otherwise these settings will 
# throw away the settings on DefaultSettings.php (you probably don't want this).
# With this line commented you will only overwrite the settings you explicitly 
# define here (that's what you probably want).
#$wgGroupPermissions = array();
$wgGroupPermissions['*'    ]['createaccount']   = false;;
$wgGroupPermissions['*'    ]['read']            = true;
$wgGroupPermissions['*'    ]['edit']            = false;
$wgGroupPermissions['bureaucrat']['renameuser'] = true;

$wgInterwikiMagic = true;

?>
  1. Fill the tables -- run ./update.php from the maintenance folder. You'll need to use a cmdline PHP to do so (so basedir doesn't come into affect), so I suggest running from CHRONOS. You'll note the $IP line in LocalSettings.php with the fullpath -- this is required to run the update.php cmd. Run from the root of the wiki site.
sudo /root/env_wrapper /opt/php5/bin/php -q /afs/eos/engrwww/ece/asic/wiki/maintenance/update.php
  1. Create folder "files-wiki" -- give the Engr Servers write access in there. This will be the file upload folder.



Upgrading from 1.5.6 to 1.6.8

  1. BACKUP both the DB and the folder.
  2. Read the UPGRADE and RELEASE-NOTES in the new version.