2011-02-11 23:58:45 +01:00
|
|
|
@title Configuration Guide
|
|
|
|
@group config
|
|
|
|
|
|
|
|
This document contains basic configuration instructions for Phabricator.
|
|
|
|
|
|
|
|
= Prerequisites =
|
|
|
|
|
|
|
|
This document assumes you've already installed all the components you need.
|
|
|
|
If you haven't, see @{article:Installation Guide}.
|
|
|
|
|
|
|
|
= Configuring MySQL =
|
|
|
|
|
|
|
|
Get MySQL running and verify you can connect to it. Consult the MySQL
|
2011-03-06 23:56:12 +01:00
|
|
|
documentation for help. When MySQL works, you need to load the Phabricator
|
|
|
|
schemata into it. First, load the initial database schema.
|
2011-02-11 23:58:45 +01:00
|
|
|
|
|
|
|
mysql -uroot < path/to/phabricator/resources/sql/init/initialize.sql
|
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
After this you need to upgrade the schema (see @{article:Upgrading Schema}),
|
2011-04-12 01:47:51 +02:00
|
|
|
but you need to finish the rest of the configuration first.
|
2011-03-06 23:56:12 +01:00
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
= Configuring Phabricator =
|
|
|
|
|
|
|
|
Create a new file here:
|
|
|
|
|
|
|
|
path/to/phabricator/conf/custom/myconfig.conf.php
|
|
|
|
|
|
|
|
...where ##myconfig## is some name which identifies your installation. Put this
|
|
|
|
in the file:
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
return array(
|
|
|
|
|
|
|
|
// Important! This will put Phabricator into setup mode to help you
|
|
|
|
// configure things.
|
|
|
|
'phabricator.setup' => true,
|
|
|
|
|
|
|
|
) + phabricator_read_config_file('production');
|
|
|
|
|
|
|
|
For the last line, you can also use ##'development'## instead of
|
|
|
|
##'production'## if you are planning to develop Phabricator itself. This will
|
|
|
|
turn on some debugging features.
|
|
|
|
|
2011-02-11 23:58:45 +01:00
|
|
|
= Configuring Apache =
|
|
|
|
|
|
|
|
Get Apache running and verify it's serving a test page. Consult the Apache
|
|
|
|
documentation for help. Make sure ##mod_php## and ##mod_rewrite## are enabled,
|
|
|
|
and ##mod_ssl## if you intend to set up SSL.
|
|
|
|
|
|
|
|
If you haven't already, set up a domain name to point to the host you're
|
|
|
|
installing on. You can either install Phabricator on a subdomain (like
|
|
|
|
phabricator.example.com) or an entire domain, but you can not install it in
|
|
|
|
some subdirectory of an existing website. Navigate to whatever domain you're
|
|
|
|
going to use and make sure Apache serves you something to verify that DNS
|
|
|
|
is correctly configured.
|
|
|
|
|
|
|
|
Now, either create a VirtualHost entry (to put Phabricator on a subdomain)
|
|
|
|
or edit the Directory entry for the DocumentRoot. It should look something like
|
|
|
|
this:
|
|
|
|
|
|
|
|
<VirtualHost *>
|
|
|
|
# Change this to the domain which points to your host.
|
|
|
|
ServerName phabricator.example.com
|
2011-03-06 23:56:12 +01:00
|
|
|
|
2011-02-11 23:58:45 +01:00
|
|
|
# Change this to the path where you put 'phabricator' when you checked it
|
|
|
|
# out from github when following the Installation Guide.
|
|
|
|
DocumentRoot /path/to/phabricator/webroot
|
2011-03-06 23:56:12 +01:00
|
|
|
|
2011-02-11 23:58:45 +01:00
|
|
|
RewriteEngine on
|
|
|
|
RewriteRule ^/rsrc/(.*) - [L,QSA]
|
|
|
|
RewriteRule ^/favicon.ico - [L,QSA]
|
|
|
|
RewriteRule ^(.*)$ /index.php?__path__=$1 [L,QSA]
|
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
# This will use the config file you set up in the previous step. If you
|
|
|
|
# called it something other than 'myconfig', put that here.
|
|
|
|
SetEnv PHABRICATOR_ENV custom/myconfig
|
2011-02-11 23:58:45 +01:00
|
|
|
</VirtualHost>
|
2011-03-06 23:56:12 +01:00
|
|
|
|
2011-02-11 23:58:45 +01:00
|
|
|
Now, restart apache and navigate to whichever subdomain you set up. You should
|
2011-05-05 20:00:05 +02:00
|
|
|
either see the Phabricator setup screen, which is a simple text page that looks
|
|
|
|
something like this:
|
|
|
|
|
|
|
|
PHABRICATOR SETUP
|
|
|
|
|
|
|
|
This setup mode will guide you through setting up your Phabricator
|
|
|
|
configuration.
|
|
|
|
|
|
|
|
>>> REQUIRED PHP EXTENSIONS ------------------------------------------------
|
|
|
|
...
|
|
|
|
|
|
|
|
If you see this, you're in good shape. Follow the instructions and correct any
|
|
|
|
problems setup detects. If you don't see it but you do see a useful error
|
|
|
|
message, try to fix that. If neither of these cover you, something is wrong.
|
|
|
|
If you can't figure it out, come get help in IRC or on the mailing list (see
|
|
|
|
http://phabricator.org/ for links).
|
2011-02-11 23:58:45 +01:00
|
|
|
|
|
|
|
= Configuring Phabricator =
|
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
Now that basic setup is complete, you should configure Phabricator for your
|
|
|
|
installation. Phabricator configuration options which control how the
|
|
|
|
applications behave are documented here:
|
2011-02-11 23:58:45 +01:00
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
/path/to/phabricator/conf/default.conf.php
|
2011-03-06 23:56:12 +01:00
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
There are several builtin configurations:
|
2011-02-11 23:58:45 +01:00
|
|
|
|
2011-02-12 01:12:02 +01:00
|
|
|
- ##default.conf.php##: root configuration, lists every configuration option
|
|
|
|
and sets some default for it. Look in this file to figure out what you can
|
2011-02-11 23:58:45 +01:00
|
|
|
configure.
|
2011-02-12 01:12:02 +01:00
|
|
|
- ##development.conf.php##: pulls in ##default.conf.php##, but overrides some
|
2011-02-11 23:58:45 +01:00
|
|
|
configuration options to better values for doing development on Phabricator.
|
|
|
|
You probably don't need to even look at this file unless you're making
|
|
|
|
changes to Phabricator itself.
|
2011-02-12 01:12:02 +01:00
|
|
|
- ##production.conf.php##: pulls in ##default.conf.php##, but overrides some
|
2011-02-11 23:58:45 +01:00
|
|
|
configuration options to provide better values for a production install.
|
2011-03-06 23:56:12 +01:00
|
|
|
|
2011-05-05 20:00:05 +02:00
|
|
|
To actually configure your install, edit your ##custom/myconfig.conf.php## file
|
|
|
|
and override values from either the ##'production'## or ##'development'##
|
|
|
|
configurations. You should not edit the builtin configurations directly because
|
|
|
|
that will make upgrading Phabricator more difficult in the future.
|
2011-04-12 01:47:51 +02:00
|
|
|
|
|
|
|
= Upgrading Schema =
|
|
|
|
|
|
|
|
After you have configured Phabricator, you need to upgrade the database
|
2011-05-05 20:00:05 +02:00
|
|
|
schema -- see @{article:Upgrading Schema}. You'll also need to do this after you
|
2011-04-30 09:18:13 +02:00
|
|
|
update the code in the future.
|