Untitled
Segue is a web-based tool which should be run from a computer that is always on and has a static ip-address. You could run it otherwise, but then it would not be accessable to users when the machine is off or when the ip-address changes.
The system requirements are minimal and Segue/Apache/MySQL runs just fine on anything that OS X will run on.
For Segue to function, you need to have working installations of Apache (with PHP) and MySQL as these provide the enviroment for Segue to run in. If you have OS X – Server, all of these may be installed already.
Apache
The Apache webserver comes installed by default on OS X.
To start/restart Apache, go to
System Preferences –> Sharing –> Services
and turn on “Personal Web Sharing”. That’s it.
PHP
Follow these excellent directions for installing PHP under OS X (might be installed by default in OS X – Server):
http://developer.apple.com/internet/opensource/php.html
As is mentioned in the documentation, you can install the need libraries using the Fink Commander front end for the Fink package management system. Fink is a great Open Source program for installing unix software on OS X. You can use it to install MySQL later as well as much (current 1509 packages) of the Open Source software that is used on other unix/unix-like systems such as Linux, FreeBSD, OpenBSD, etc.
MySQL
MySQL is the database used by Segue. Either install it via Fink Commander, mentioned above, or follow these detailed directions from Apple:
http://developer.apple.com/internet/opensource/osdb.html
– Apple.com
If you need to install MySQL and are unsure how you want to install it, just use Fink/FinkCommander. Anything you install with Fink/FinkCommander can be upgraded easily with Fink and installation is a two-click process. Very easy.
To manage (create, create users, etc) your MySQL databases, you can either use the MySQL command line utility, a database client such as CocoaMySQL, or a web-based client such as PHPMyAdmin.
Set Up a MySQL Database for Segue
To set up a MySQL account and database for Segue.
(Using PHPMyAdmin)
- Point your browser to http://localhost/phpmyadmin/
-
Create a database for Segue
Click “Home” in the top-left of PHPMyAdmin.
Enter a database name, i.e. “segue”; then hit “Create”. -
Add a “segue” user
Go to Home –> Privileges –> Add a New User
Enter a username and password, i.e. “segue”, “secret”. Set host to “localhost”, as this will prevent anyone from using this account from remotely accessing the database. Then hit “Go”. -
Give the “segue” user access to the “segue” database.
If you have just created the “segue” user, you should already be at the correct screen if not, got to Privileges –> Edit (next to the “segue” user).
Go down to the “Database-specific privileges” section and select the “segue” database from the drop-down menu.
Check all of the Data and Structure boxes then hit “Go”.
Set Up Segue
-
Download Segue
Download the latest version of Segue
from SourceForge.net.
-
Untar Segue
Untar the segue-1.x.x.tar.gz file into your webserver’s root directory,
/Library/WebServer/Documents/
you can either let StuffIt decompress the archive or do it from the command line with:
tar -xzf /Library/WebServer/Documents/segue-1.x.x.tar.gz
This will create a directory called segue-1.x.x in /Library/WebServer/Documents/ . Rename this directory to “segue”. -
Create a userfiles directory
Create a directory for the Segue userfiles. This directory is outside of the segue directory to allow you to update the Segue code without loosing the userfiles. you should now have a “segue” and a “segue_userfiles” directories in /Library/WebServer/Documents/. -
Configure Segue
Rename the file /Library/WebServer/Documents/segue/config_sample.inc.php to “config.inc.php”.
Open config.inc.php in a text editor (such as the included “TextEdit”) and edit the various values to fit your system.
Below are examples of the parts that you must change:
Untitled
* full_uri – Segue’s full URL path (ie, https://segue.middlebury.edu/view/html/site/segue)
* Don’t put a slash “/” at the end of the url!
******************************************************************************/
$cfg[full_uri] = $_full_uri = “http://140.233.12.105/segue”;
Contact your network administrator to set up a DNS hostname and static IP address for your server to give you a url such as https://segue.middlebury.edu/view/html/site/segue/
/******************************************************************************
* uploaddir – the local folder where userfiles are kept
* uploadurl – the URL equivalent of the above folder
******************************************************************************/
$cfg[uploaddir] = $uploaddir = “/Library/WebServer/Documents/segue_userfiles”;
$cfg[uploadurl] = $uploadurl = “http://140.233.12.105/segue_userfiles”;
/******************************************************************************
* DB AUTHENTICATION – REQUIRED
*
* dbhost the hostname of the sql server (ie, sql.middlebury.edu)
* dbuser the user to connect as (ie, segue)
* dbpass the above user’s passwd. may be blank
* dbdb the name of the database to use (ie, segue)
******************************************************************************/
$cfg[dbhost] = $dbhost = “localhost”;
$cfg[dbuser] = $dbuser = “segue”;
$cfg[dbpass] = $dbpass = “secret”;
$cfg[dbdb] = $dbdb = “segue”;
Start Segue
Point your browser to http://localhost/segue/ or http://xxx.xxx.xxx.xxx/segue/ (where the xxx’s are your IP address) to use Segue.
The first time that you go to Segue, you should see messages saying that Segue created the necessary tables in your database.
Log in with user/pass admin/changeme to start using Segue.
Enjoy!