CentOS 레드마인 설치

Jmnote (토론 | 기여)님의 2017년 6월 1일 (목) 18:26 판 (→‎사전 작업)
  다른 뜻에 대해서는 우분투 레드마인 설치 문서를 참조하십시오.
Crystal Clear action info.png 작성 중인 문서입니다.
How To Install Redmine
레드마인 설치하기

1 사전 작업

2 redmin DB 생성

Console
Copy
[root@zetawiki ~]# mysql -uroot -p
Enter password: P@ssw0rd
Console
Copy
mysql> create database redmine character set utf8;
Query OK, 1 row affected (0.04 sec)

mysql> create user 'redmine'@'localhost' identified by 'P@ssw0rd';
Query OK, 0 rows affected (0.04 sec)

mysql> grant all privileges on redmine.* to 'redmine'@'localhost';
Query OK, 0 rows affected (0.02 sec)

mysql> flush privileges; 
Query OK, 0 rows affected (0.00 sec)

mysql> exit
Bye

3 passenger 설치

Console
Copy
[root@zetawiki ~]# gem install passenger
Fetching: rack-2.0.3.gem (100%)
Successfully installed rack-2.0.3
Fetching: passenger-5.1.4.gem (100%)
Building native extensions.  This could take a while...
Successfully installed passenger-5.1.4
Parsing documentation for rack-2.0.3
Installing ri documentation for rack-2.0.3
Parsing documentation for passenger-5.1.4
Installing ri documentation for passenger-5.1.4
Done installing documentation for rack, passenger after 39 seconds
2 gems installed

4 gem 업데이트, bundler 설치

Console
Copy
[root@zetawiki ~]# gem -v
2.6.12
Console
Copy
[root@zetawiki ~]# gem update
Updating installed gems
Updating bigdecimal
Fetching: bigdecimal-1.3.2.gem (100%)
... (생략)
Parsing documentation for xmlrpc-0.3.0
Done installing documentation for xmlrpc after 0 seconds
Gems updated: bigdecimal did_you_mean json minitest openssl power_assert psych rdoc test-unit xmlrpc
Console
Copy
[root@zetawiki ~]# gem install bundler
Fetching: bundler-1.15.0.gem (100%)
Successfully installed bundler-1.15.0
Parsing documentation for bundler-1.15.0
Installing ri documentation for bundler-1.15.0
Done installing documentation for bundler after 7 seconds
1 gem installed
Console
Copy
[root@zetawiki ~]# bundler -v
Bundler version 1.15.0

5 레드마인 설치

Console
Copy
[root@zetawiki ~]# wget https://github.com/redmine/redmine/archive/3.3.3.tar.gz
... (생략)
2017-06-01 15:29:19 (938 KB/s) - “3.3.3.tar.gz” saved [2384478]
Console
Copy
[root@zetawiki ~]# tar xvzf 3.3.3.tar.gz
redmine-3.3.3/
redmine-3.3.3/.gitignore
redmine-3.3.3/.hgignore
... (생략)
redmine-3.3.3/tmp/test/empty
redmine-3.3.3/tmp/thumbnails/
redmine-3.3.3/tmp/thumbnails/empty
Console
Copy
[root@zetawiki ~]# mv redmine-3.3.3/ /usr/share/redmine
[root@zetawiki ~]# cd /usr/share/redmine/
[root@zetawiki redmine]# ll
total 80
drwxrwxr-x  6 root root 4096 Apr  9 17:47 app
-rw-rw-r--  1 root root  851 Apr  9 17:47 appveyor.yml
drwxrwxr-x  2 root root 4096 Apr  9 17:47 bin
drwxrwxr-x  5 root root 4096 Apr  9 17:47 config
-rw-rw-r--  1 root root  160 Apr  9 17:47 config.ru
-rw-rw-r--  1 root root  241 Apr  9 17:47 CONTRIBUTING.md
drwxrwxr-x  3 root root 4096 Apr  9 17:47 db
drwxrwxr-x  2 root root 4096 Apr  9 17:47 doc
drwxrwxr-x  5 root root 4096 Apr  9 17:47 extra
drwxrwxr-x  2 root root 4096 Apr  9 17:47 files
-rw-rw-r--  1 root root 3934 Apr  9 17:47 Gemfile
drwxrwxr-x  7 root root 4096 Apr  9 17:47 lib
drwxrwxr-x  2 root root 4096 Apr  9 17:47 log
drwxrwxr-x  2 root root 4096 Apr  9 17:47 plugins
drwxrwxr-x  8 root root 4096 Apr  9 17:47 public
-rw-rw-r--  1 root root  275 Apr  9 17:47 Rakefile
-rw-rw-r--  1 root root  205 Apr  9 17:47 README.rdoc
drwxrwxr-x  2 root root 4096 Apr  9 17:47 script
drwxrwxr-x 10 root root 4096 Apr  9 17:47 test
drwxrwxr-x  5 root root 4096 Apr  9 17:47 tmp
Console
Copy
[root@zetawiki redmine]# bundle install
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your
bundle as root will break this application for all non-root users on this machine.
Please configure your config/database.yml first
... (생략)
Fetching rails 4.2.7.1
Installing rails 4.2.7.1
Bundle complete! 30 Gemfile dependencies, 70 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.

6 레드마인 DB 설정

Console
Copy
[root@zetawiki ~]# mysql -uroot -p
Enter password: P@ssw0rd
Console
Copy
mysql> create database redmine character set utf8;
Query OK, 1 row affected (0.04 sec)

mysql> create user 'redmine'@'localhost' identified by 'P@ssw0rd';
Query OK, 0 rows affected (0.04 sec)

mysql> grant all privileges on redmine.* to 'redmine'@'localhost';
Query OK, 0 rows affected (0.02 sec)

mysql> exit
Bye
Console
Copy
[root@zetawiki ~]# vi /usr/share/redmine/config/database.yml
yaml
Copy
production:
  adapter: mysql2
  database: redmine
  host: localhost
  username: root
  password: "P@ssw0rd"
  encoding: utf8

7 같이 보기

8 참고 자료