# "script/server -e production" doesn't work

**URL:** <https://www.ruby-forum.com/t/script-server-e-production-doesnt-work/93561>\
**Category:** Rails\
**Created:** [April 4, 2006, 8:18pm UTC](https://www.ruby-forum.com/t/script-server-e-production-doesnt-work/93561 "2006-04-04T20:18:24Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dnstevenson](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/8dc957/32.png) [@dnstevenson](https://www.ruby-forum.com/u/dnstevenson)\
**Post date:** [April 4, 2006, 8:18pm UTC](https://www.ruby-forum.com/t/script-server-e-production-doesnt-work/93561/1 "2006-04-04T20:18:24Z")

</div>

I’ve got an error that’s only happening on my live webserver, so wanted  
to  
test on my local machine in the production environment.

On my local machine, I tried to run…

script/server -e production

… but get: server: invalid option: -e

Has this been disabled or renamed in 1.1?

I’m running gem Rails 1.1, Ruby 1.8.4, and the server is Lighttpd  
1.3.16.

Thanks,

~Dave

–

Dave S.  
Rent-A-Monkey Website Development

> **[Tree Removal Service For Home & Businesses in Salt Lake City, UT](https://www.rentamonkey.com/)**
>
> Rent A Monkey Tree Service provides the safest, highest-quality tree removal for Salt Lake City, UT homes and businesses. Request a service today!

PGP Key: [http://www.rentamonkey.com/pgpkey.asc](http://www.rentamonkey.com/pgpkey.asc)

---

<div class="post-metadata">

**Author:** ![dnstevenson](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/8dc957/32.png) [@dnstevenson](https://www.ruby-forum.com/u/dnstevenson)\
**Post date:** [April 4, 2006, 8:24pm UTC](https://www.ruby-forum.com/t/script-server-e-production-doesnt-work/93561/2 "2006-04-04T20:24:35Z")

</div>

On Tue, 2006-04-04 at 19:16 +0100, Dave S. wrote:

> I’m running gem Rails 1.1, Ruby 1.8.4, and the server is Lighttpd 1.3.16.

* * *

try launching with  
ruby script/server -e production

but note, you can only have one server for each port so if you have  
production running already on default port, it won’t work. But

ruby script/server -e production -p 3100

should work (of course, users wanting to connect to ‘production’ would  
have to use things like localhost:3100)

Craig

---

<div class="post-metadata">

**Author:** ![dnstevenson](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/8dc957/32.png) [@dnstevenson](https://www.ruby-forum.com/u/dnstevenson)\
**Post date:** [April 4, 2006, 8:43pm UTC](https://www.ruby-forum.com/t/script-server-e-production-doesnt-work/93561/3 "2006-04-04T20:43:07Z")

</div>

On Tuesday 04 Apr 2006 19:22, Craig W. wrote:

> try launching with  
> ruby script/server -e production  
> but note, you can only have one server for each port so if you have  
> production running already on default port, it won’t work. But  
> ruby script/server -e production -p 3100  
> should work (of course, users wanting to connect to ‘production’ would  
> have to use things like localhost:3100)

Thanks Craig, but I’m afraid that still doesn’t work. I normally do run  
it  
with “ruby” in front, but that doesn’t make any difference here. This  
is on  
my local machine, and it’s definitely not running the server already.

FWIW, just to simulate that error, if I try to run two servers (in two  
different terminal windows) I get:

2006-04-04 19:35:49: (network.c.235) can’t bind to port 3443 Address  
already  
in use

So just to confirm: completely different error message for if what you  
think  
might be happening was happening. This is on Gentoo Linux, if that  
makes any  
difference. It’s a site running in SSL mode on Lighttpd using a  
self-signed  
certificate.

Has been working fine for ages, and will run in production mode if I  
make the  
switch in my environment.rb - it just won’t run in production straight  
from  
the command line.

Cheers,

~Dave

–

Dave S.  
Rent-A-Monkey Website Development

> **[Tree Removal Service For Home & Businesses in Salt Lake City, UT](https://www.rentamonkey.com/)**
>
> Rent A Monkey Tree Service provides the safest, highest-quality tree removal for Salt Lake City, UT homes and businesses. Request a service today!

PGP Key: [http://www.rentamonkey.com/pgpkey.asc](http://www.rentamonkey.com/pgpkey.asc)
