Guide for rapid creation of an instance of TRAC September 2010 - Mali AROC EN $ sudo bash (type your password) # hostname tldX.aroc (replace X with your number) # apt-get install apache2 # apt-get install trac # apt-get install libapache2-mod-python We will make trac available on . * Create a trac directory to contain the project # mkdir -p /var/www/trac # chown www-data /var/www/trac # chmod 775 /var/www/trac * Initialise the project # trac-admin /var/www/trac initenv (press enter on all questions) # chown -R www-data /var/www/trac * Initialise the base user # htpasswd -c /var/www/trac/.htpasswd tldadmin (choose a password, enter it twice) # chown -R www-data /var/www/trac * Update trac.ini (your site configuration) # vi /var/www/trac/conf/trac.ini (you can use vi or nano orÉ) Edit in the order below [header_logo] alt = AROC EN Workshop Mali, TLD X height = 52 link = http://10.10.10.X/trac/ src = site/some-logo.jpg width = 422 [project] descr = AROC EN Workshop Mali, TLD X footer = AROC EN Workshop Mali, TLD X name = AROC EN Workshop Mali, TLD X * Save and quit the editor * We need to change the user permissions. Copy/paste the following commands, EACH ON ONE LINE! # trac-admin /var/www/trac permission remove anonymous MILESTONE_VIEW REPORT_SQL_VIEW REPORT_VIEW ROADMAP_VIEW SEARCH_VIEW TICKET_VIEW TIMELINE_VIEW # trac-admin /var/www/trac permission add authenticated MILESTONE_VIEW MILESTONE_MODIFY REPORT_SQL_VIEW REPORT_VIEW ROADMAP_VIEW SEARCH_VIEW TICKET_VIEW TIMELINE_VIEW * We now give access to the web administrator "tldadmin" # trac-admin /var/www/trac permission add tldadmin TRAC_ADMIN # trac-admin /var/www/trac upgrade * We tell Apache how to find the site # vi /etc/apache2/conf.d/trac.conf SetHandler mod_python PythonHandler trac.web.modpython_frontend PythonOption TracEnv /var/www/trac PythonOption TracUriRoot /trac SetEnv PYTHON_EGG_CACHE /var/www/trac/python-eggs AuthType Basic AuthName "AROC En TLD XXX" AuthUserFile /var/www/trac/.htpasswd Require valid-user * Save and quit the editor * Done! Restart apache: # /etc/init.d/apache2 restart * You can put a logo in JPG form and specify the file name in conf/trac.ini * Try to go to http://10.10.10.X/trac (log in as tldadmin) * Create a home page For help with the wiki markup format: http://10.10.10.X/trac/wiki/WikiFormatting