- install xcode tools from installation cd
- install Macports. go to: http://www.macports.org/
- sudo port selfupdate
- sudo port install mysql5 +server
- sudo port install ruby
- sudo port install rb-rubygems
- sudo port install rb-termios
- sudo port install rb-mysql
- sudo port install subversion +tools
- sudo port install git-core
- sudo port install freetds
- sudo port install rb-dbi +dbd_odbc
- sudo port install rb-odbc
- sudo ln -s /opt/local/var/run/mysql5/mysqld.sock /tmp/mysql.sock
- sudo launchctl load -w /Library/LaunchDaemons/org.macports.mysql5.plist
- sudo mysql_install_db5 –user=mysql
- sudo gem install -y rake
- sudo gem install -y rails
- sudo gem install -y capistrano
- sudo gem install -y mongrel
- sudo gem install -y mongrel_cluster
- install eclipse
- install Aptana plugin
- install Aptana Radrails plugin
Oracle is offering to buy Sun at $9.50 per share (http://news.yahoo.com/s/ap/20090420/ap_on_bi_ge/oracle_sun). That is bad news for Sun, Java and MySQL. Sun bought MySQL and I thought it was a great idea to compete with Oracle. Now MySQL is under Oracle and you know Oracle is going to kill MySQL because they don’t want free open source database to compete with their product. It is time to fork MySQL to a different open source project so that it won’t be controlled by Oracel.
Just created a website called MoMingle.com using ror plus a few plugins including geo-kit and twitter4r. It allows people to post location-based messages. It is definitely a good learning experience for me to design and build this website.
I have successfully moved all my ruby on rails websites to slicehost. No more Godaddy. Slicehost is great. Best hosting provider ever.
I have two of my ruby on rails web sites running on Godaddy and for the past two days it just suddenly stopped working. Their tech support didn’t know why and still tried to figure out. When I first called them, one of their tech support guys blame me. It is time to switch to other hosting company.
Please! All the software developers especially Java developers. Stop over engineering. Stop using abstract factory when there is no need. Stop making it configurable when it doesn’t need to be. Make it simple. I am reading a piece code that right now which have a class that is an abstractfactory to create another factory. Crazy!
I have to say. JRuby on Rails is very cool. It is so easy now to deploy to Tomcat and JBoss. I tried and did it on both server and it ran like a champ. Here is the steps (Mac OS X):’
- sudo port install jruby
- sudo chmod a+w /opt/local/share/java/jruby/lib/ruby/gems/ and all the directory underneath it
- sudo chmod a+w /opt/local/share/java/jruby/bin
- jruby -S gem install rails mongrel jdbc-mysql activerecord-jdbcmysql-adapter activerecord-jdbc-adapter jruby-openssl warbler –no-rdoc –no-ri
- sudo port tomcat5 (or you can install jboss. Just download and unpack it to a directory)
- jruby -S rails your_rails_project
- cd your_rails_project
- generate a simple model: jruby script/generate scaffold car model:string
- create a development database:my_own_development in mysql
- change config/database.yml:
- development:
adapter: jdbcmysql
database: my_own_devevelopment
pool: 5
timeout: 5000
host: localhost
username: root
password: - jruby rake db:migrate
- jruby -S warble config
- change config/warble.rb file:
- make sure: config.gems += [”activerecord-jdbcmysql-adapter”, “jruby-openssl”,”activerecord-jdbc-adapter”,”jdbc-mysql”] #include all the gems you need
- make sure: config.webxml.rails.env = ENV[’RAILS_ENV’] || ‘production’ # point to the environment you want. By default it is production
- make sure you are on your rails project’s root directory
- jruby -S warble war
- that will create war file like your_rails_project.war
- cp your_rails_project.war to your tomcat_home/webapps directory or your jboss_home/server/default/deploy directory
- start tomcat or start jboss
- go http://localhost:8080/your_rails_project/ to check if your project has deployed. To see the scaffold car go http://localhost:8080/your_rails_project/cars
Google usually changes their logo for special days like new year, mother’s day, etc. Today, Google missed Chinese new year. Yahoo didn’t miss it. Google did. One for yahoo. Zero for Google. That makes me wondering. Is Google anti-Chinese?
My time at this recent startup company will soon over. We had the best people with lot of money and trying to change the health care industry using latest web 2.0 technologies and features. However, we always been lacking is a clear vision and business model. After close to 200 millions and many layoff later, the company is sold to another one for probably 25 cents on the dollars with the hope that the combined company will have a better future. The final business model coming down to CPM (ads model). The company is no longer a health company but a content company. So in the end, it is about money. If you don’t have a business model to make money, you won’t last no matter how many smart people you have and how much money you have. I never regret that I worked for this company. In the end, I have learned a lot. The journey was wonderful no matter what the destination is.