以前にホスティングサーバ上にRedmineを入れようとして失敗し、そのまま放置していたが、やっぱりRedmineが使いたくなったので再調査。
何かいい方法(できればお金をかけず)がないか探していたところ、Redhatが提供するOpenShiftというPaaS上に構築できることが判明。しかも無料。早速試してみる。
まずはOpenShift Onlineのアカウントを作る。
次にOpenShiftをいじくる環境を整備。rhcという独自のクライアントツールを使うようで、これにはrubyとgitが必要らしい。「Getting Started with OpenShift Online」を参考に環境を整える。
まずはRubyのインストール。Ruby Installerを使って最新版(投稿時2.2.2)を入れればOK。
次にGitのインストール。既にインストール済みなので割愛。
続いてRubyGemsを使ってrhcをインストール。
C:\>gem install rhc
続いてrhcのセットアップ。
C:\>rhc setup C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- dl/import (LoadError) from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/net-ssh-2.9.2/lib/net/ssh/authentication/pageant.rb:1:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/net-ssh-2.9.2/lib/net/ssh/authentication/agent/socket.rb:5:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/net-ssh-2.9.2/lib/net/ssh/authentication/agent.rb:22:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/net-ssh-2.9.2/lib/net/ssh/authentication/key_manager.rb:4:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/net-ssh-2.9.2/lib/net/ssh/authentication/session.rb:4:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/net-ssh-2.9.2/lib/net/ssh.rb:11:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/ssh_helpers.rb:18:in `<top (required)>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/wizard.rb:77:in `<class:Wizard>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/wizard.rb:7:in `<module:RHC>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/wizard.rb:6:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/commands/base.rb:4:in `<top (required)>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/commands/account.rb:2:in `<module:Commands>' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/commands/account.rb:1:in `<top (required)>' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/commands.rb:189:in `block in load' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/commands.rb:188:in `each' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/commands.rb:188:in `load' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/lib/rhc/cli.rb:36:in `start' from C:/Ruby22/lib/ruby/gems/2.2.0/gems/rhc-1.36.4/bin/rhc:20:in `<top (required)>' from C:/Ruby22/bin/rhc:23:in `load' from C:/Ruby22/bin/rhc:23:in `<main>'
おーい。。。
調べてみると、どうやらnet-ssh-2.9.2が悪いのかnet-ssh-2.9.3beta1を入れろと書いてある。あるいはrubyを1.9.3にするか。
どちらにしようか悩んだが、beta版を入れるのはあまり好きではないし、Gettng Startedでは1.9.3を入れているようなので1.9.3に入れなおすことにする。
一旦2.2.2をアンインストールして1.9.3をインストール。
その後、rhcのインストールもやり直し。
先ほどは出なかったドキュメントのインストールエラーが出るが、ドキュメントなので放置。
気を取り直してrhcのセットアップを。
C:\>rhc setup OpenShift Client Tools (RHC) Setup Wizard (省略) Your client tools are now configured.
何とか成功したよう。
とりあえず今日はここまで。
次回こそRedmineのインストールを。