Installation/Arcavias Core/Setup/en

This article is about Arcavias Core Release 2014.03. For documentation of older versions please check the Archive.

Create a database
After you've installed the MySQL database server you need to create a database where the Arcavias tables will be created in. First, log into your database server using the MySQL command line client:

mysql -u root -p

Afterwards, create the database and grant access to an user account:

CREATE DATABASE arcavias; GRANT ALL on arcavias.* TO arcavias IDENTIFIED BY ' '; QUIT

Create the resource file
The ./config/ directory of the Arcavias source code contains a resource.php-dist file that is a good template for your own configuration. Adapt the file now to match your database setup. The configuration file contains one or more main sections, the most important one is called "db" for the database configuration which requires this settings:


 * adapter : The name of the database adapter used for connecting to the database server. Currently only "mysql" is available
 * host : Name or IP address for server which hosts the database. This can also be a path to a local file or socket, use "localhost" if your database server is on the same machine
 * port : Port where the database server is listening for requests. This is usually port "3306"
 * database : Name of the database which should be used for creating the tables and storing the data. In the section before we used the name "arcavias"
 * username : Name of the database account you've granted access to the database. In the section before we used the name "arcavias"
 * password : Secret password for authentication that you've entered instead of ' ' in the statements before
 * stmt : List of statements that are executed after creating a new database connection. Leave this as is as long as you don't know what you are doing
 * limit : Maximum number of allowed database connections. Leave this at its default value (2) as long as you don't know what you are doing

Setup the tables
Creating the required database structure and adding the necessary default data is rather simple. There are setup tasks available that will create the required tables and insert the necessary default data. On the command line, execute

cd php setup.php

Please replace " " with the real directory in your file system. To add also the unit test data to the tables simply use the phing command:

phing setup

For more information about phing, have a look at the phing article.

Archive

 * Arcavias Core 2014-01 and before

<< Previous: Install | Next: Run tests >>