ChefとCapistranoの境界線 (Chef Casual Talks Vol.1) #eytokyo #opschef_jaMasahiro NAKAYAMA
ChefとCapistranoの境界線 (Chef Casual Talks Vol.1) #eytokyo #opschef_jaMasahiro NAKAYAMA
Capistrano、便利ですよね。 capistrano/capistrano 最近メジャーバージョンアップがあったのですが、使い方、というかスクリプトの書き方やお作法が変わり、「Capistrano 3にアップデートしたはいいけど全然動かなくてどうなってんだ」という流れはもはやお約束みたいです。 試しに僕も個人で作ってるウェブサイトのCapistranoをアップデートしてみたので、その上でこんなところに気を付けたいな、と思うポイントでも書いておきます。 capifyは使わない Capistranoを使うときは$ bundle installをし、次に$ bundle exec capify .とするのがお約束の流れですが、これからはcapifyを使ってもcap installを使ってねと言われます。 ですので: $ bundle exec cap installとしましょう。 マルチス
前回ブログに書いたbitBucketを本格的に使おうと思い bitBucket+Capistranoでデプロイできるように設定しました。 もともとsvnでは使用していたもののgitになると勝手が違う。。 設定を行うついでに、capistrano-extをインストールして、 multistageというコマンド実行時にデプロイ先を選択できるように作りました。 これでいちいちdeploy.rbを書き換えること無くProduction,Staging,Develop それぞれのサーバーに配置できるように! こういう感じの構成↓ ということで以下手順。 GITのインストール 前書いた記事↓ gitをさくらサーバーへインストールする方法 http://d.hatena.ne.jp/oggata/20100201/1266908009 rubyのインストール cd /usr/local/src wget
アプリサーバーで使うパッケージのセットアップを chef-solo で自動化できたけど、Ruby と chef をインストールする作業は手作業のまま。この部分も自動化したい。 そこで Capistrano を使って Ruby と chef をインストールするスクリプトを書いてみた。 # coding: utf-8 set :application, "<app name>" set :user, "<username>" set :port, 10022 set :ruby_version, "1.9.3-p194" role :app, "<host name>" default_run_options[:pty] = true desc "git tasks" namespace :git do desc "install git" task :install, :roles => :
chef 見習いの @tk0miya です。全国の chef 使いのみなさん、いかがお過ごしでしょうか。 最近、自分が使っている VM に入っている ruby の数を調べてみてびっくりしました。 OS 標準のもの (/usr/bin/ruby) Chef Omnibus Installer 由来のもの (/opt/chef/omnibus/bin/ruby) RVM 由来のもの (/home/xxxx/.rvm/...) Vagrant 由来のもの (/usr/local/bin/ruby) このうち、アプリケーションが利用しているのは RVM 由来のものだけです。 更に調べてみると、このうち 3箇所に chef がインストールされている不思議な状態になっていました。 今回はこの環境を整理して、RVM にまとめてみたいと思います。実験環境は CentOS 6.3 です。 capistran
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く