3

I have a small Ruby script that I want to run by visiting a page in a browser. This might seem like a dumb question but what's the easiest way to accomplish this? I haven't found very good documentation on how to get Ruby working with Apache so I'm open to any suggestions at this point.

3
  • Terminology nitpick: server-side applications don't run in the browser, they run on the server. The only programming language that runs in the browser is javascript (and vbscript, I suppose). Commented Jan 27, 2011 at 19:44
  • 1
    mod_ruby embeds ruby in the apache web server. Commented Jan 27, 2011 at 19:46
  • @sepp2k: I've edited my language. @The MYYN: Have you gotten that to actually work yourself? I haven't had success with it. Commented Jan 27, 2011 at 19:47

1 Answer 1

4

I suggest Sinatra. As shown on that page, it's very lightweight, and Apache is not even necessary. As you get to needing more performance you might use Nginx or Apache as a reverse proxy (serving your static files quickly) and something like Thin to make your application run faster.

But for now, just start using Sinatra. As shown on the home page, you can get started in just a few lines.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.