Source

trac-ticketlinks / wiki-default / TracEnvironment

= Trac Storage - The Environment =
Trac uses a directory structure and an embedded [http://www.sqlite.org/ SQLite] database as storage.

== Creating an Environment ==
A new Trac environment is created using [wiki:TracAdmin trac-admin], like:

{{{
$ trac-admin /path/to/projectenv initenv
}}}

[wiki:TracAdmin trac-admin] will ask you where your subversion repository is located and
where it can find the trac templates directory (the default value should work for a typical install).

'''Note:''' The web server user will require file system write permission to the environment
directory and all the files inside. '''Remember to set the appropriate permissions.''

The same applies for the subversion repository files (unless using the [http://svn.collab.net/repos/svn/trunk/notes/fsfs FSFS Subversion backend], something we highly recommend. 



== Directory Structure ==
{{{
 EnvDir
   |-- README
   |-- VERSION
   |-- attachments
   |   |-- ticket
   |   `-- wiki
   |-- conf
   |   `-- trac.ini
   |-- db
   |   `-- trac.db
   |-- log
   |   `-- trac.log
   |-- templates
   |   |-- site_css.cs
   |   |-- site_footer.cs
   |   `-- site_header.cs
   `-- wiki-macros
}}}

 * '''README''' - Brief description of the environment.
 * '''VERSION''' - Contains the environment version identifier.
 * '''attachments''' - All attached files go in here.
   * '''ticket''' - Ticket attachments.
   * '''wiki''' - Wiki attachments.
 * '''conf'''
   * '''trac.ini''' - Main configuration file. See TracIni.
 * '''db'''
   * '''trac.db''' - SQLite database.
 * '''templates''' - Custom (environment-specific) templates.
   * '''site_css.cs''' - Custom CSS stylesheet.
   * '''site_footer.cs''' - Custom footer.
   * '''site_header.cs''' - Custom header.
 * '''wiki-macros''' - Environment-specific WikiMacros.

----
See also: TracBackup, TracIni, TracGuide
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.