From mboxrd@z Thu Jan 1 00:00:00 1970 Delivered-To: chneukirchen@gmail.com Received: by 10.229.49.16 with SMTP id t16cs7804qcf; Mon, 27 Sep 2010 22:41:32 -0700 (PDT) Return-Path: Received-SPF: pass (google.com: domain of rack-devel+bncCLiT7L3gBRCIgIblBBoE-ESRHQ@googlegroups.com designates 10.115.100.20 as permitted sender) client-ip=10.115.100.20; Authentication-Results: mr.google.com; spf=pass (google.com: domain of rack-devel+bncCLiT7L3gBRCIgIblBBoE-ESRHQ@googlegroups.com designates 10.115.100.20 as permitted sender) smtp.mail=rack-devel+bncCLiT7L3gBRCIgIblBBoE-ESRHQ@googlegroups.com; dkim=pass header.i=rack-devel+bncCLiT7L3gBRCIgIblBBoE-ESRHQ@googlegroups.com Received: from mr.google.com ([10.115.100.20]) by 10.115.100.20 with SMTP id c20mr3324935wam.24.1285652490730 (num_hops = 1); Mon, 27 Sep 2010 22:41:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=beta; h=domainkey-signature:received:x-beenthere:received:mime-version :received:received:date:in-reply-to:x-ip:references:user-agent :x-http-useragent:message-id:subject:from:to:x-original-sender :reply-to:precedence:mailing-list:list-id:list-post:list-help :list-archive:sender:list-subscribe:list-unsubscribe:content-type :content-transfer-encoding; bh=Q8+AvjHnI7UcCU9aHCaLMFUY8iy2aSZ39IijIEKoU98=; b=en0hb61dvUUodCoHnhnogTZspFytmTbhm4fgsplfz4o9HTmcLOAupn47PcuaGO/Paq 1n2UO4ox+4+lqZl/8ZSYUfS2TAMmDjLAY2BqLbDQ+lk5e6FiyrhuND8pr3yGIMM9SaDy eCMx+hGxqudSi23bBriCoxExtsmddZTl/VK24= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlegroups.com; s=beta; h=x-beenthere:mime-version:date:in-reply-to:x-ip:references :user-agent:x-http-useragent:message-id:subject:from:to :x-original-sender:reply-to:precedence:mailing-list:list-id :list-post:list-help:list-archive:sender:list-subscribe :list-unsubscribe:content-type:content-transfer-encoding; b=D4eIdROWDZRt1yzED+UF9ySl8oz3BXUTdnS1PDxH437edZK4x1FLsC0bUxr2tHSX0M AGcmnawjyyYLgPsaD9wVq8kl0Dv+Px9ZD3wt+cHCCXEx5XVLq4z4Kd+3Et9/hsMrVLV7 d7fZcjMSN1xiAgyLQQ1Hu37f0iYdPkMjnCoO0= Received: by 10.115.100.20 with SMTP id c20mr681615wam.24.1285652488967; Mon, 27 Sep 2010 22:41:28 -0700 (PDT) X-BeenThere: rack-devel@googlegroups.com Received: by 10.115.98.19 with SMTP id a19ls5035908wam.1.p; Mon, 27 Sep 2010 22:41:28 -0700 (PDT) MIME-Version: 1.0 Received: by 10.114.137.8 with SMTP id k8mr681927wad.20.1285652488312; Mon, 27 Sep 2010 22:41:28 -0700 (PDT) Received: by x18g2000pro.googlegroups.com with HTTP; Mon, 27 Sep 2010 22:41:28 -0700 (PDT) Date: Mon, 27 Sep 2010 22:41:28 -0700 (PDT) In-Reply-To: <6C0F22B1-AC07-4624-9133-388CD00297D8@gmail.com> X-IP: 67.169.42.39 References: <6C0F22B1-AC07-4624-9133-388CD00297D8@gmail.com> User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.7 (KHTML, like Gecko) Chrome/7.0.517.17 Safari/534.7,gzip(gfe) Message-ID: Subject: Re: Fix daemonize behavior broken since 1.0.1 From: Andrew Bortz To: Rack Development X-Original-Sender: andrew.bortz@gmail.com Reply-To: rack-devel@googlegroups.com Precedence: list Mailing-list: list rack-devel@googlegroups.com; contact rack-devel+owners@googlegroups.com List-ID: List-Post: , List-Help: , List-Archive: Sender: rack-devel@googlegroups.com List-Subscribe: , List-Unsubscribe: , Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Yup, you did (in a different way) and I totally missed it. Thanks! - Andrew On Sep 24, 7:15=A0am, James Tucker wrote: > iirc, I fixed this in master already. > > On 23 Sep 2010, at 18:52, Andrew Bortz wrote: > > > > > > > > > When rackup is run in daemonize mode, it fails to read the default > > config file. In fact, it accepts a config file argument, but unless > > that argument is an absolute path, it will also fail to load. The best > > way I can think of to fix that is to resolve the absolute path of the > > config file before the server is forked off (and chdir's to '/'). > > > - Andrew > > > diff --git a/lib/rack/server.rb b/lib/rack/server.rb > > index 8ef973c..edec62b 100644 > > --- a/lib/rack/server.rb > > +++ b/lib/rack/server.rb > > @@ -226,6 +226,7 @@ module Rack > > =A0 =A0 =A0 =A0args.clear if ENV.include?("REQUEST_METHOD") > > > =A0 =A0 =A0 =A0options.merge! opt_parser.parse! args > > + =A0 =A0 =A0 =A0options[:config] =3D ::File.expand_path(options[:confi= g]) > > =A0 =A0 =A0 =A0ENV["RACK_ENV"] =3D options[:environment] > > =A0 =A0 =A0 =A0options > > =A0 =A0 =A0end