scaffold: mysql can't connect and more - OS X Tiger
I finally decided to jump and learn! I just bought the Agile Web Dev with Rails book and so far so good, except I've now hit a wall. I've changed my config file to match the db settings, but everytime I run the scafoold script I get this:
I've tried different users, I tried the old_password() thing but still nothing. What is going on here folks? Smooth sailing until this.
$ sudo ./script/generate scaffold product admin
Access denied for user: 'root@localhost' (Using password: YES)
I'm running OS X 10.4.3 with the latest MySQL 4 update. I've used gem to update everything. Actually, another weird problem: when I use gem to install mysql, I get a strange error:
Now that's one I serisouly don't get? Can't find Ruby header files? Hmm...
sudo gem install mysql
Attempting local installation of 'mysql'
Local gem file not found: mysql*.gem
Attempting remote installation of 'mysql'
Building native extensions. This could take a while...
can't find header files for ruby.
ERROR: While executing gem ... (RuntimeError)
ERROR: Failed to build gem native extension.
Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/mysql-2.7 for inspection.
ruby extconf.rb install mysql\n
Results logged to /usr/lib/ruby/gems/1.8/gems/mysql-2.7/gem_make.out
Thanks in advance!