{"id":4219,"date":"2018-05-30T18:26:39","date_gmt":"2018-05-30T14:26:39","guid":{"rendered":"https:\/\/www.howtoforge.com\/tutorial\/ubuntu-trac-project-management-tool\/"},"modified":"2018-05-30T18:26:39","modified_gmt":"2018-05-30T14:26:39","slug":"how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts","status":"publish","type":"post","link":"https:\/\/afaghhosting.net\/blog\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts\/","title":{"rendered":"How to Install Trac Project Management Tool on Ubuntu 18.04 LTS"},"content":{"rendered":"<p>Trac is a free and an open source Web-based project management and bug tracking system that helps developers to write great software while staying out of the way. You can easily integrate Trac with version control systems like Subversion and Git. Trac allows wiki markup in issue descriptions and commit messages, creating links and seamless references between bugs, tasks, changesets, files and wiki pages.<\/p>\n<p>In this tutorial, we will learn how to install Trac on Ubuntu 18.04 LTS (Bionic Beaver).<\/p>\n<h2 id=\"requirements\">Requirements<\/h2>\n<ul>\n<li>A server running Ubuntu 18.04.<\/li>\n<li>A non-root user with sudo privileges.<\/li>\n<\/ul>\n<h2 id=\"install-apache\">Install Apache<\/h2>\n<p>First, you will need to install Apache web server to your system. You can install Apache with the following command:<\/p>\n<p class=\"command\">sudo apt-get install apache2 -y<\/p>\n<p>Once Apache is installed, start Apache service and enable it to start on boot with the following command:<\/p>\n<p class=\"command\">sudo systemctl start apache2<br \/>sudo systemctl enable apache2<\/p>\n<h2 id=\"install-and-configure-trac\">Install and Configure Trac<\/h2>\n<p>By default, Trac is available in Ubuntu 18.04 repository. You can install Trac with the following command:<\/p>\n<p class=\"command\">sudo apt-get install trac libapache2-mod-wsgi -y<\/p>\n<p>Once Trac is installed, enable auth_digest module with the following command:<\/p>\n<p class=\"command\">sudo a2enmod auth_digest<\/p>\n<p>Next, you will need to create a web root directory for Trac. You can do this by running the following command:<\/p>\n<p class=\"command\">sudo mkdir \/var\/lib\/trac<br \/>sudo mkdir -p \/var\/www\/html\/trac<br \/>sudo chown www-data:www-data \/var\/www\/html\/trac<\/p>\n<p>Next, create a project directory for Trac and give proper permissions with the following command:<\/p>\n<p class=\"command\">sudo trac-admin \/var\/lib\/trac\/test initenv test sqlite:db\/trac.db<\/p>\n<p>Output:<\/p>\n<pre>Project environment for 'test' created.&#13;\n&#13;\nYou may now configure the environment by editing the file:&#13;\n&#13; \/var\/lib\/trac\/test\/conf\/trac.ini&#13;\n&#13;\nIf you'd like to take this new project environment for a test drive,&#13;\ntry running the Trac standalone web server `tracd`:&#13;\n&#13; tracd --port 8000 \/var\/lib\/trac\/test&#13;\n&#13;\nThen point your browser to http:\/\/localhost:8000\/test.&#13;\nThere you can also browse the documentation for your installed&#13;\nversion of Trac, including information on further setup (such as&#13;\ndeploying Trac to a real web server).&#13;\n&#13;\nThe latest documentation can also always be found on the project&#13;\nwebsite:&#13;\n&#13; http:\/\/trac.edgewall.org\/&#13;\n&#13;\nCongratulations!&#13;\n<\/pre>\n<p class=\"command\">sudo trac-admin \/var\/lib\/trac\/test deploy \/var\/www\/html\/trac\/test<br \/>sudo chown -R www-data:www-data \/var\/lib\/trac\/test<br \/>sudo chown -R www-data:www-data \/var\/www\/html\/trac\/test<\/p>\n<p>Next, create an admin user and hiroom2 user for Trac with the following command:<\/p>\n<p class=\"command\">sudo htdigest -c \/var\/lib\/trac\/test\/.htdigest &#8220;test&#8221; admin<br \/>sudo htdigest \/var\/lib\/trac\/test\/.htdigest &#8220;test&#8221; hiroom2<\/p>\n<h2 id=\"configure-apache-for-trac\">Configure Apache for Trac<\/h2>\n<p>Next, you will need to create an Apache virtual host directive for Trac. You can do this by running the following command:<\/p>\n<p class=\"command\">sudo nano \/etc\/apache2\/sites-available\/trac.conf<\/p>\n<p>Add the following lines:<\/p>\n<pre>WSGIScriptAlias \/trac\/test \/var\/www\/html\/trac\/test\/cgi-bin\/trac.wsgi&#13;\n&lt;Location \/trac\/test&gt;&#13; AuthType Digest&#13; AuthName \"test\"&#13; AuthUserFile \/var\/lib\/trac\/test\/.htdigest&#13; Require valid-user&#13;\n&lt;\/Location&gt;&#13;\n<\/pre>\n<p>Save and close the file, when you are finished.<\/p>\n<p>Finally, enable Trac virtual host and restart Apache service with the following command:<\/p>\n<p class=\"command\">sudo a2ensite test<br \/>sudo systemctl restart apache2<\/p>\n<h2 id=\"access-trac-web-interface\">Access Trac Web Interface<\/h2>\n<p>Trac is now installed and configured, it&#8217;s time to access Trac web interface.<\/p>\n<p>Open your web browser and type the URL <strong>http:\/\/your-domain-name\/trac\/test<\/strong>, you will be redirected to the following page:<\/p>\n<p><a class=\"fancybox\" id=\"img-page1\" href=\"https:\/\/www.howtoforge.com\/images\/how_to_install_trac_project_management_tool_on_ubuntu_1804\/big\/page1.png\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/05\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts.png\" alt=\"Login to Trac\" width=\"550\" height=\"171\" title=\"\"><\/a><\/p>\n<p>Now, provide your admin user credentials and click on the Log In button, you should see the following page:<\/p>\n<p><a class=\"fancybox\" id=\"img-page2\" href=\"https:\/\/www.howtoforge.com\/images\/how_to_install_trac_project_management_tool_on_ubuntu_1804\/big\/page2.png\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/05\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts-1.png\" alt=\"Trac Web Interface\" width=\"550\" height=\"325\" title=\"\"><\/a><\/p>\n<div>\n<p><b>Share this page:<\/b><\/p>\n<p>\n<a href=\"https:\/\/www.facebook.com\/sharer.php?u=https%3A%2F%2Fwww.howtoforge.com%2Ftutorial%2Fubuntu-trac-project-management-tool%2F\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/05\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts-2.png\" height=\"20\" alt=\"\" title=\"\"><\/a><br \/>\n<a href=\"https:\/\/twitter.com\/intent\/tweet?url=https%3A%2F%2Fwww.howtoforge.com%2Ftutorial%2Fubuntu-trac-project-management-tool%2F&amp;text=How+to+Install+Trac+Project+Management+Tool+on+Ubuntu+18.04+LTS&amp;via=howtoforgecom&amp;related=howtoforgecom\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/05\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts-3.png\" height=\"20\" alt=\"\" title=\"\"><\/a><br \/>\n<a href=\"https:\/\/twitter.com\/howtoforgecom\/\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/05\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts-4.png\" height=\"20\" alt=\"\" title=\"\"><\/a><br \/>\n<a href=\"https:\/\/plus.google.com\/share?url=https%3A%2F%2Fwww.howtoforge.com%2Ftutorial%2Fubuntu-trac-project-management-tool%2F\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/05\/how-to-install-trac-project-management-tool-on-ubuntu-18-04-lts-5.png\" height=\"20\" alt=\"\" title=\"\"><\/a>\n<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Trac is a free and an open source Web-based project management and bug tracking system that helps developers to write great software while staying out of the way. You can easily integrate Trac with version control systems like Subversion and Git. Trac allows wiki markup in issue descriptions and commit messages, creating links and seamless &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[36],"tags":[],"class_list":["post-4219","post","type-post","status-publish","format-standard","hentry","category-36"],"_links":{"self":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/4219","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/comments?post=4219"}],"version-history":[{"count":0,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/4219\/revisions"}],"wp:attachment":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/media?parent=4219"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/categories?post=4219"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/tags?post=4219"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}