heroku
herokuを使う。
$ sudo yum -y install rubygems
$ gem install -r -p http://server:port/ heroku
$ gem install heroku
$ mkdir cramps && cd cramps
$ git init
$ touch README
$ git add .
$ git commit -m "cramps"
$ heroku create
git push heroku master
project url
Ruby on Rails 3 アプリケーションプログラミング
- 作者: 山田祥寛
- 出版社/メーカー: 技術評論社
- 発売日: 2011/05/12
- メディア: 大型本
- 購入: 27人 クリック: 664回
- この商品を含むブログ (41件) を見る
PaaS
Google App Engine以外にも触手を伸ばす。
アカウント取得
http://www.fluxflex.com/
http://no.de/
http://www.heroku.com/
プロジェクト作成
cname
$ dig meteors.psychobil.ly
;; QUESTION SECTION:
;meteors.psychobil.ly. IN A;; ANSWER SECTION:
meteors.psychobil.ly. 3539 IN CNAME 30dd3f0df6cfe4d7dab5eacfac3eacb2c137e11c.dns.fluxflex.com.
30dd3f0df6cfe4d7dab5eacfac3eacb2c137e11c.dns.fluxflex.com. 86339 IN CNAME meteors.fluxflex.com.
meteors.fluxflex.com. 86339 IN CNAME app1.fluxflex.com.
app1.fluxflex.com. 86339 IN CNAME applb-1833250967.us-east-1.elb.amazonaws.com.
applb-1833250967.us-east-1.elb.amazonaws.com. 60 IN A 50.19.84.175
- 作者: 日経BP社出版局
- 出版社/メーカー: 日経BP社
- 発売日: 2010/04/22
- メディア: 単行本
- 購入: 11人 クリック: 1,429回
- この商品を含むブログ (22件) を見る
分散失敗
glusterfsでの分散ファイルシステム構築失敗。
peer probeでノード追加してvolume作成して、mountまでは出きるが参照が出来ない(参照しようとすると応答が無くなる)。
当面はs3で凌ぐことにする。
s3fsはレスポンス遅すぎるのでキャッシュ効かせないと辛い。
memo
firefox add-ons
Installing RPMforge
CentOSでRPMforgeパッケージを使えるようにする。
参考
http://wiki.centos.org/AdditionalResources/Repositories/RPMForge
install
$ sudo rpm --import http://apt.sw.be/RPM-GPG-KEY.dag.txt
$ sudo rpm -K http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm
http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm: (sha1) dsa sha1 md5 gpg OK
$ sudo rpm -ivh http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm
http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm を取得中
準備中... ########################################### [100%]
1:rpmforge-release ########################################### [100%]
$ sudo yum -y install htop
cms
wordpress保留。
eZ Publish無料版を試してみる。
install
$ curl http://share.ez.no/content/download/118008/553423/version/3/file/ezpublish_community_project-2011.8-with_ezc.tar.bz2 -o ezpublish_community_project-2011.8-with_ezc.tar.bz2
$ tar xvjf ezpublish_community_project-2011.8-with_ezc.tar.bz2
$ sudo mv ezpublish_community_project-2011.8-with_ezc /usr/local/nginx
$ cd /usr/local/nginx
$ sudo ln -s ezpublish_community_project-2011.8-with_ezc ezpublish
$ cat /usr/local/nginx/conf/nginx.confserver {
listen 80;
server_name frenzy.psychobil.ly;location / {
root /usr/local/nginx/ezpublish;
index index.html index.htm index.php;
deny 216.13.56.89;
}location ~ \.php$ {
root /usr/local/nginx/ezpublish;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}server_tokens off;
}php依存パッケージ
$ sudo yum -y install php-xmlfascgi再起動
$ sudo /etc/init.d/php-fastcgi stop
$ sudo /etc/init.d/php-fastcgi start
db準備
$ mysql -uroot -p
mysql> CREATE DATABASE ez CHARACTER SET utf8;
mysql> GRANT ALL ON ez.* TO ez@localhost IDENTIFIED BY 'xxx';
mysql> GRANT ALL ON ez.* TO ez@"ip-10-xxx-xxx-aaa.ap-northeast-1.compute.internal" IDENTIFIED BY 'xxx';
mysql> GRANT ALL ON ez.* TO ez@"ip-10-xxx-xxx-bbb.ap-northeast-1.compute.internal" IDENTIFIED BY 'xxx';
mysql> FLUSH PRIVILEGES;
nginx サブドメイン設定
blog用にサブドメインを設定。
.
.
# blog - wordpress
server {
listen 80;
server_name frenzy.psychobil.ly;
location / {
root html/wordpress;
index index.html index.htm index.php;
deny 216.13.56.89;
}location ~ \.php$ {
root html/wordpress;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}server_tokens off;
}
.
.
- 作者: Clement Nedelcu,長尾高弘
- 出版社/メーカー: アスキー・メディアワークス
- 発売日: 2011/04/21
- メディア: 大型本
- 購入: 2人 クリック: 714回
- この商品を含むブログ (23件) を見る