redmineインストール

http://d.hatena.ne.jp/navyfox_sh/20090121/1232552014
http://redmine.jp/tech_note/install/
http://d.hatena.ne.jp/sugarball/20091013/1255350068

sudo port install ruby
sudo port install rb-rubygems
sudo gem install rails 
むむ!
RubyGems will revert to legacy indexes degrading performance.
Bulk updating Gem source index for: http://gems.rubyforge.org/
ERROR: While executing gem ... (Gem::RemoteSourceException)
Error fetching remote gem cache: bad response Not Found 404 (http://production.s3.rubygems.org/yaml)

こっちか?
sudo port install rb-rails

どっちにしてもgemでエラー!
次の日動いた!リポジトリがダウンしてただけ?

sudo gem install passenger

export APXS2=/opt/local/apache2/bin/apxs
export PATH=/opt/local/apache2/bin/:$PATH
sudo passenger-install-apache2-module

Please edit your Apache configuration file, and add these lines:
LoadModule passenger_module /opt/local/lib/ruby/gems/1.8/gems/passenger-2.2.14/ext/apache2/mod_passenger.so
PassengerRoot /opt/local/lib/ruby/gems/1.8/gems/passenger-2.2.14
PassengerRuby /opt/local/bin/ruby


$ rake config/initializers/session_store.rb

mysql> grant all privileges on redmine.* to redmine identified by '(Redmine用パスワード)';

sudo env ARCHFLAGS="-arch x86_64" gem install mysql -- --with-mysql-config=/opt/local/bin/mysql_config5

/opt/local/apache2/htdocs/redmine/config/database.yml(編集)
production:
adapter: mysql
database: redmine
host: localhost
username: root
password: (MySQLredmine用に設定したパスワード)
encoding: utf8

sudo gem update --system
さいごかたまる

$ sudo gem update rails
異常にながい

cd /opt/local/apache2/htdocs/redmine
sudo rake db:migrate RAILS_ENV=production
エラー
rake aborted!
RubyGem version error: rack(1.1.0 not ~> 1.0.1)
(See full trace by running task with --trace)

vi /opt/local/apache2/htdocs/redmine/vendor/rails/actionpack/lib/action_controller.rb
rack(1.1.0に変更

ここにきてMySQLのエラー
rake aborted!
Can't connect to local MySQL server through socket '/opt/local/var/run/mysql5/mysqld.sock' (2)



ServerName www.yourhost.com
DocumentRoot /somewhere/public # <-- be sure to point to 'public'!

AllowOverride all # <-- relax Apache security settings
Options -MultiViews # <-- MultiViews must be turned off

なかなかmysqlがはいらないmacports

とりあえずシンボリックリンクはりまくって
データディレクト初期化スクリプトはながれたっぽい

http://www2.nl.freebsd.org/mysql/doc/refman/5.1/ja/mysql-install-db.html

sudo -u mysql /opt/local/bin/mysql_install_db5 --basedir=/opt/local/lib/mysql5 --datadir=/opt/local/var/db/mysql


起動
/opt/local/lib/mysql5/bin/mysqld_safe &

接続
/opt/local/lib/mysql5/bin/mysql