# Run rails on cd

**URL:** <https://www.ruby-forum.com/t/run-rails-on-cd/151410>\
**Category:** Rails\
**Created:** [October 21, 2008, 5:10am UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410 "2008-10-21T05:10:09Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 21, 2008, 5:10am UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/1 "2008-10-21T05:10:09Z")

</div>

Dear

is there a way that we can rails on cd. for example, a dictionary book  
has a cd and they asked me to do software for that. since i am  
familiar with rails, i prefer to do it on rails. So, can we have a way  
to run the application from the cd. Note the applocation is read only

thanks

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 21, 2008, 5:56am UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/2 "2008-10-21T05:56:45Z")

</div>

Hi Shuaib:  
Rails run in development or production mode, since you cant disable log  
of dev or prodt. You can use rails stand alone CD, like Ruby on Rails  
Portable and what about database? ouhave to think about it too. unless  
you linked logs to another hardisk drive of user.

Reinhart  
[Http://Teapoci.BlogSpot.com](Http://Teapoci.BlogSpot.com)

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 21, 2008, 9:09am UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/3 "2008-10-21T09:09:35Z")

</div>

Well, it seems you misunderstood me

The application is a read only application from the user side. The  
user is only going to view the matrerial and not to write anything.  
So, database will be readonly on the cd. As for the logs emmm. Will  
think of a way to disable them. But I am not sure whether we can have  
ruby on rails running on cd.

On Oct 21, 11:56 am, Rails T. \<rails-mailing-l…@andreas-

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 21, 2008, 5:07pm UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/4 "2008-10-21T17:07:35Z")

</div>

Have you checked out Joyent Slingshot? Not sure if it’s what you’re  
looking for, but its worth a look.

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 21, 2008, 12:37pm UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/5 "2008-10-21T12:37:21Z")

</div>

Shuaib85 wrote:

> Well, it seems you misunderstood me
> 
> The application is a read only application from the user side. The  
> user is only going to view the matrerial and not to write anything.  
> So, database will be readonly on the cd. As for the logs emmm. Will  
> think of a way to disable them. But I am not sure whether we can have  
> ruby on rails running on cd.

You need a web server - to get a web server your CD would have to be a  
bootable Linux (or other CD) that started a webserver and GUI - whether  
you can actually implement this and then persuade a user to boot off it  
are probably bigger problems than whether your application will work on  
a read only filesystem (though you could easily run a RAM disk if you  
got that far).

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 22, 2008, 5:55am UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/6 "2008-10-22T05:55:40Z")

</div>

Hi, thanks for the replies.

Joyent Slingshot seems like the one, but the website is down (:

anyway, thanks

I wish that I can find someone who did it

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 22, 2008, 12:30pm UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/7 "2008-10-22T12:30:19Z")

</div>

Shuaib85 wrote:

> Well, it seems you misunderstood me
> 
> The application is a read only application from the user side. The  
> user is only going to view the matrerial and not to write anything.  
> So, database will be readonly on the cd. As for the logs emmm. Will  
> think of a way to disable them. But I am not sure whether we can have  
> ruby on rails running on cd.

If the application is read only, then you might be able to get away  
with a framework like webby: [http://webby.rubyforge.org/](http://webby.rubyforge.org/)

It will generate static HTML. You can probably get away without even  
running a webserver.

If that won’t work for you, I’d suggest you look at InstantRails  
(assuming all your clients run Windows). I used this once for an app  
that had to run locally (i.e. we couldn’t have a webserver). But you  
are still looking at a headache to try to run it ONLY from the CD. You  
could probably create an easy installer though.

---

<div class="post-metadata">

**Author:** ![shuaib85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/bbce88/32.png) [@shuaib85](https://www.ruby-forum.com/u/shuaib85)\
**Post date:** [October 22, 2008, 1:44pm UTC](https://www.ruby-forum.com/t/run-rails-on-cd/151410/8 "2008-10-22T13:44:46Z")

</div>

On 21 Oct 2008, at 03:08, Shuaib85 wrote:

> Well, it seems you misunderstood me
> 
> The application is a read only application from the user side. The  
> user is only going to view the matrerial and not to write anything.  
> So, database will be readonly on the cd. As for the logs emmm. Will  
> think of a way to disable them. But I am not sure whether we can have  
> ruby on rails running on cd.

the database could just be sqlite3 which will be quite happy with a  
read only file system.  
As far as the logs go, the easiest way would probably to set the  
logger to a custom Logger subclass that doesn’t do anything at all.  
I imagine you could easily write a quick shell script/batch file/etc  
that spun up a webrick server and pointed the users’ browser at it.  
You could probably rig it so that the entire ruby environment was on  
the cd (if not the user would have to have ruby installed)

Fred
