基於Windows Server 2012 R2 x64搭建Redmine

來源:互聯網
上載者:User

標籤:Redmine

  • Highlight:

    1. 參考文檔:http://www.redmine.org/projects/redmine/wiki/RedmineInstall

    2. mysql和redmine在同一台主機上,實際部署時可單獨部署mysql。

    3. 本文不包括整合Apache/Nginx。

    4. 以下內容在virtualbox虛擬機器上測試可行。


    • OS環境


    作業系統:Windows Server 2012 R2 x64 英文標準版(MSDN下載ISO)

    安裝完系統後,安裝以下patch,這些patch都可以從微軟官方網站下載:

    clearcompressionflag.exe

    vcredist_x64.exe

    Windows8.1-KB2919355-x64.msu

    Windows8.1-KB2919442-x64.msu

    Windows8.1-KB2932046-x64.msu

    Windows8.1-KB2934018-x64.msu

    Windows8.1-KB2937592-x64.msu

    Windows8.1-KB2938439-x64.msu

    Windows8.1-KB2959977-x64.msu


    • 資料庫搭建


    下載mysql-5.5.59-winx64.msi後按照安裝嚮導及實際需求完成安裝,安裝完畢,執行以下sql建立空資料庫redmine及使用者redmine,並賦予使用者redmine所有許可權。

    CREATE DATABASE redmine CHARACTER SET utf8;

    CREATE USER 'redmine'@'Server2012-05' IDENTIFIED BY 'redmine';

    GRANT ALL PRIVILEGES ON redmine.* TO 'redmine'@'Server2012-05';


    注意:推薦使用mysql-5.5,5.5之後的版本和redmine相容上存在問題,我自己試過多個版本,折騰很久,最後還是用mysql-5.5最方便。



    • Redmine安裝


    (1)部署Redmine應用程式套件

    從http://www.redmine.org/releases/redmine-3.4.4.zip 下載Redmine壓縮包,然後解壓至C:\redmine-3.4.4

    (2)安裝ruby, rubyGems

    下載並按照安裝嚮導的預設設定安裝以下軟體,下載連結見參考文獻:

    rubyinstaller-2.3.3-x64.exe

    DevKit-mingw64-64-4.7.2-20130224-1432-sfx.exe

    安裝完畢,修改環境變數path,添加C:\Ruby23-x64\bin,C:\DevKit\bin和C:\DevKit\mingw\bin,如下所示:

    %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;

    %SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;

    C:\Program Files\MySQL\MySQL Server 5.5\bin; C:\Ruby23-x64\bin;C:\DevKit\bin;C:\DevKit\mingw\bin

    確認版本:

    C:\Windows\system32>ruby -v

    ruby 2.3.3p222 (2016-11-21 revision 56859) [x64-mingw32]


    C:\Windows\system32>gem -v

    2.5.2

    (3)安裝bundle >= 1.5.0

    在cmd中執行:

    gem install bundle

    (4)安裝其他依賴包

    修改C:\redmine-3.4.4\Gemfile,將gem "mysql2", "~> 0.4.6"改為gem "mysql2", "0.4.6"。

    cd c:\redmine-3.4.4

    bundle install –without development test rmagick

    (5)產生會話秘鑰

    cd c:\redmine-3.4.4

    bundle exec rake generate_secret_token

    (6)產生資料庫結構

    cd c:\redmine-3.4.4

    set RAILS_ENV=production

    bundle exec rake db:migrate

    (7)啟動Redmine

    cd c:\redmine-3.4.4

    ruby bin/rails server -e production –b 0.0.0.0

    (8)登入Redmine

    從區域網路內任意機器訪問http://Redmine_Host_IP:3000

     

    預設賬戶及密碼為admin/admin。

    使用admin賬戶登入,系統會強制使用者修改密碼,請牢記住修改後的密碼!

    基於Windows Server 2012 R2 x64搭建Redmine

    相關文章

    聯繫我們

    該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

    如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.