2020年3月12日 星期四

如何在Ubuntu 18.04上安裝Redmine


參考以下影片

https://www.youtube.com/watch?v=vaRwqhImDVU


# su root
# apt-get install apache2 libapache2-mod-passenger
# apt-get install mysql-server mysql-client
# mysql -u root -p
# apt-get install redmine redmine-mysql
# gem update
# gem install bundler
   
# vim /etc/apache2/mods-available/passenger.conf

<IfModule mod_passenger.c>
  PassengerDefaultUser www-data
  PassengerRoot /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini
  PassengerDefaultRuby /usr/bin/ruby
</IfModule>


# ln -s /usr/share/redmine/public /var/www/html/redmine
     
# vim /etc/apache2/sites-available/000-default.conf

       ServerAdmin webmaster@localhost
        DocumentRoot /var/www/html
<Directory /var/www/html/redmine>
RailsBaseURI /redmine
PassengerResolveSymlinksInDocumentRoot on
</Directory>


 # service apache2 restart
# touch /usr/share/redmine/Gemfile.lock
# chown www-data:www-data /usr/share/redmine/Gemfile.lock
# chown -R www-data:www-data /etc/redmine/default/