LoginSignup
11
11

More than 5 years have passed since last update.

boxenでの構築でハマった所メモ

Last updated at Posted at 2013-12-13
  • 不要なバージョンをコメントアウトする(コンパイルが長くなるし)
manifests/site.pp
  # node versions
  ## no need old version
  #include nodejs::v0_4
  #include nodejs::v0_6
  #include nodejs::v0_8
  include nodejs::v0_10

  # default ruby versions
  ## no need old version
  #include ruby::1_8_7
  #include ruby::1_9_2
  #include ruby::1_9_3
  include ruby::2_0_0
  • firevalutを使わない時は、オプションつける
$ script/boxen --no-fde
  • nodeのバージョンが指定されていないというエラーが出るので、明示的に指定しておく
manifests/site.pp
  # NodeJS stuff
  class { 'nodejs::global':
    version => 'v0.10'
  }
  • デフォルトで入ったrubyは readline の接続先の問題で、irbに日本語が通らないので、接続先を直す
manifests/site.pp
  ## for ruby readline
  package {
    [
      'readline',
    ]:
  }
  # readlineの接続先直す | iii ThreeTreesLight
  # http://threetreeslight.com/post/58786169382/readline
  exec{ "replace_readline_of_ruby" :
   command => "find /opt/boxen/rbenv -name readline.bundle -exec install_name_tool -change /usr/lib/libedit.3.dylib `find /opt/boxen -name libreadline.dylib` {} \\;",
  }
  • rbenv の globalを設定
manifests/site.pp
  # set ruby global version
  class { 'ruby::global':
    version => '2.0.0'
  }
  • [注意] boxenで入った memcacahed や mysql 等のdaemon系?は起動ポートがデフォルトと違う。 基本的に prefix が BOXEN の環境変数に入っている
$ echo $BOXEN_MEMCACHED_PORT
21211
$ echo $BOXEN_MYSQL_PORT
13306

詳細は、boxen/puppet-memcached,boxen/puppet-mysql 等を見ると、rails等の設定サンプルが書いてあったりするので、とりあえず確認すると吉

11
11
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
11
11