Getting Rails to work on WinXP

R

Robo

I'm trying to the 10min Setup video tutorial, but the video's slightly
outdated, and my environment's a bit different.

I've got Ruby 1.8, WinXP, Apache2, and MySQL working. I installed Rails
via RubyGems, and I want to use it without virtual hosts, but simply as
a subfolder in my regular www directory.

The provided Apache conf file assumes I'm using VirtualHost, so I
modified it to:

<Directory /blog/public>
Options ExecCGI FollowSymLinks
AllowOverride all
Allow from all
Order allow,deny
</Directory>

Because I used gems, the default files are not actually in the www
directory like in the video. I've manually copied the folder across for now.

Inside E:\www\blog, I ran "ruby script/new_controller Weblog", and it
created the weblog_controller.rb file in E:\www\app\controllers\, but
when I go to http://localhost/blog/weblog, I simply get a 404 error,
which I half expected, 'cos there's no weblog folder in the blog folder.
In the video it seems to execute the controller scripts, but I can't get
that to work.

So, say I was to start a project from scratch in my environment, how
would I do it, to get Rails to print my hello world?

Robo
 
G

Gavin Sinclair

I'm trying to the 10min Setup video tutorial, but the video's slightly
outdated, and my environment's a bit different.
I've got Ruby 1.8, WinXP, Apache2, and MySQL working. I installed Rails
via RubyGems, and I want to use it without virtual hosts, but simply as
a subfolder in my regular www directory.

Have you tried the Windows-specific videos at

http://www.rubyonrails.org/show/RailsAcademy

?

I got started with that no problem.

Gavin
 
N

Nicholas Van Weerdenburg

I'm trying to the 10min Setup video tutorial, but the video's slightly
outdated, and my environment's a bit different.

I've got Ruby 1.8, WinXP, Apache2, and MySQL working. I installed Rails
via RubyGems, and I want to use it without virtual hosts, but simply as
a subfolder in my regular www directory.

The provided Apache conf file assumes I'm using VirtualHost, so I
modified it to:

<Directory /blog/public>
Options ExecCGI FollowSymLinks
AllowOverride all
Allow from all
Order allow,deny
</Directory>

Because I used gems, the default files are not actually in the www
directory like in the video. I've manually copied the folder across for now.

Inside E:\www\blog, I ran "ruby script/new_controller Weblog", and it
created the weblog_controller.rb file in E:\www\app\controllers\, but
when I go to http://localhost/blog/weblog, I simply get a 404 error,
which I half expected, 'cos there's no weblog folder in the blog folder.
In the video it seems to execute the controller scripts, but I can't get
that to work.

So, say I was to start a project from scratch in my environment, how
would I do it, to get Rails to print my hello world?

Robo

Does rails still require mod_rewrite for pretty urls in Apache?

I'm still using webbrick on Windows-
"ruby public/dispatch.servlet" from the root directory.

Regards,
Nick
 
R

Robo

I've already got mod_rewrite enabled prior to installing Rails. Using
gems instead of tgz, and not using VirtualHosts makes the situation a
bit different to the tutorials, so still unable to get it working.

Robo
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,821
Latest member
AleidaSchi

Latest Threads

Top