John Beppu | 10 Mar 17:33 2008
Picon

Camping is a winner at SXSW-i

Last night, a little Camping application I wrote called MetaNotes won the Experimental division in the SXSW Web Awards.

MetaNotes is a site that lets you (and many other people) simultaneously place colorful post-it notes on a wide canvas.  If you get lucky, you may see notes move in the background as other people (or robots) make changes to the space you happen to be in.

I must warn you that it's very alpha at the moment, so be gentle with the site.  In my estimation, it's only about 60% done, and we were surprised to even be finalists.

----

Anyway, I'm writing this email to thank everyone who worked on Camping and made it the beautiful little web microframework that it is.  My favorite part of Camping is the way controllers are expressed.  It gives me so much control over URLs, and I love how the controllers are RESTful by default.  That was a brilliant idea.

--beppu

PS:  During the web awards, we must've been sitting at the lucky table.  There were 3 teams at the table, and at the end of the night, that table had 4 awards.  I wish I had taken a picture.  (The MetaNotes crew was sitting w/ people from Wikinvest and Launchball.  We all won our respective categories, and Launchball won something else at the end.)  How crazy is that.


_______________________________________________
Camping-list mailing list
Camping-list@...
http://rubyforge.org/mailman/listinfo/camping-list
pedro mg | 10 Mar 17:56 2008

Fwd: Camping is a winner at SXSW-i

On 3/10/08, John Beppu <john.beppu@...> wrote:
 > Last night, a little Camping application I wrote called MetaNotes won the
 > Experimental division in the SXSW Web Awards.

Hey, congrats John ;) Very well indeed.
Camping is in fact very cool.

--
pedro mg
http://blog.tquadrado.com
Jonathan Stott | 11 Mar 11:30 2008
Picon

Dropping Root

Hello Campers

I'm not sure this is the right list to ask but: 
I'm using the junebug wiki (which is written in camping) for my own personal wiki.  I'd like it to behave as a
proper daemon, so it will start up at boot, get stopped properly at shutdown, keep a pid file in /var/run etc.

This requires a little messing with the wiki script junebug makes in the wiki directory (changing the
dirmode to system, amongst other things). Junebug uses the daemons gem for this purpose, for those who
haven't looked at the gem. This  works and I can copy the wiki script to /etc/init.d/ and add the appropriate
runlevel symlinks with update-rc.d.

Which all works great.  Except that I end with the process running as root. Which makes me twitchy and
nervous. So I'd to like to make it step down like a good little process to a much less privileged user. I can't
do this in the /etc/init.d/ script, as it then can't write the pid file (and probably other things).  But
putting it in the setup post amble doesn't seem to work (the wiki is still root)

So where should my Process.uid statements go?

Regards,
Jon.
John Turner | 11 Mar 12:42 2008

Re: Dropping Root

I was playing with some setuid and camping for a project myself.  I
don't see if you've mentioned this, but I assume you're using the
camping server to run it?  I ended up just editing the camping server
script to change uid and chroot just after its requires (I also edited
it to do all its requires up front because I was chrooting and to just
use mongrel just because).  I'm not sure what the problem with doing
this in the postamble would be though, are you sure it's getting run?
Is it getting run every time camping reloads the script?  How exactly
are you setting the uid?

John

On 11/03/2008, Jonathan Stott <jonathan.stott@...> wrote:
> Hello Campers
>
>  I'm not sure this is the right list to ask but:
>  I'm using the junebug wiki (which is written in camping) for my own personal wiki.  I'd like it to behave as a
proper daemon, so it will start up at boot, get stopped properly at shutdown, keep a pid file in /var/run etc.
>
>  This requires a little messing with the wiki script junebug makes in the wiki directory (changing the
dirmode to system, amongst other things). Junebug uses the daemons gem for this purpose, for those who
haven't looked at the gem. This  works and I can copy the wiki script to /etc/init.d/ and add the appropriate
runlevel symlinks with update-rc.d.
>
>  Which all works great.  Except that I end with the process running as root. Which makes me twitchy and
nervous. So I'd to like to make it step down like a good little process to a much less privileged user. I can't
do this in the /etc/init.d/ script, as it then can't write the pid file (and probably other things).  But
putting it in the setup post amble doesn't seem to work (the wiki is still root)
>
>  So where should my Process.uid statements go?
>
>  Regards,
>  Jon.
>  _______________________________________________
>  Camping-list mailing list
>  Camping-list@...
>  http://rubyforge.org/mailman/listinfo/camping-list
>
Jonathan Stott | 11 Mar 14:33 2008
Picon

Re: Dropping Root

No, junebug uses the Mongrel Camping handler (which is set up in the same postamble) which I know is invoked,
as I can change messages in there and they are reflected in the logs, for example.

the postamble looks like:
connect to DB
create tables
Invoke the Mongrel::Camping handler
set up some signal traps
join the server thread.
(or see a pastie of the actual code here: 
http://pastie.caboo.se/164364 )

I'm trying to set the uid via 'Process.uid = ###', which I've tried at various points through the post amble,
both before and after the join, but it still seems to be running as root when I check ps.

Regards, Jonathan 

On Tue, 11 Mar 2008 11:42:52 +0000
"John Turner" <john.turner@...> wrote:

> I was playing with some setuid and camping for a project myself.  I
> don't see if you've mentioned this, but I assume you're using the
> camping server to run it?  I ended up just editing the camping server
> script to change uid and chroot just after its requires (I also edited
> it to do all its requires up front because I was chrooting and to just
> use mongrel just because).  I'm not sure what the problem with doing
> this in the postamble would be though, are you sure it's getting run?
> Is it getting run every time camping reloads the script?  How exactly
> are you setting the uid?
> 
> John
> 
John Beppu | 11 Mar 16:09 2008
Picon

Re: Dropping Root

Having you considered using rv?

http://blog.evanweaver.com/files/doc/fauna/rv/files/README.html


On Tue, Mar 11, 2008 at 5:30 AM, Jonathan Stott <jonathan.stott-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
Hello Campers

I'm not sure this is the right list to ask but:
I'm using the junebug wiki (which is written in camping) for my own personal wiki.  I'd like it to behave as a proper daemon, so it will start up at boot, get stopped properly at shutdown, keep a pid file in /var/run etc.


_______________________________________________
Camping-list mailing list
Camping-list@...
http://rubyforge.org/mailman/listinfo/camping-list
John Turner | 11 Mar 16:10 2008

Re: Dropping Root

I was using Process::UID.change_privilege(uid), which seems to do the
job (in irb at least) where Process.uid= doesn't, it seems like it
should though.  There's grant_privelege too, but I don't know what the
difference between that and change_privilege is.

Hope that helps.

John

On 11/03/2008, Jonathan Stott <jonathan.stott@...> wrote:
> No, junebug uses the Mongrel Camping handler (which is set up in the same postamble) which I know is
invoked, as I can change messages in there and they are reflected in the logs, for example.
>
>  the postamble looks like:
>  connect to DB
>  create tables
>  Invoke the Mongrel::Camping handler
>  set up some signal traps
>  join the server thread.
>  (or see a pastie of the actual code here:
>  http://pastie.caboo.se/164364 )
>
>  I'm trying to set the uid via 'Process.uid = ###', which I've tried at various points through the post
amble, both before and after the join, but it still seems to be running as root when I check ps.
>
>  Regards, Jonathan
>
>
>  On Tue, 11 Mar 2008 11:42:52 +0000
>  "John Turner" <john.turner@...> wrote:
>
>  > I was playing with some setuid and camping for a project myself.  I
>  > don't see if you've mentioned this, but I assume you're using the
>  > camping server to run it?  I ended up just editing the camping server
>  > script to change uid and chroot just after its requires (I also edited
>  > it to do all its requires up front because I was chrooting and to just
>  > use mongrel just because).  I'm not sure what the problem with doing
>  > this in the postamble would be though, are you sure it's getting run?
>  > Is it getting run every time camping reloads the script?  How exactly
>  > are you setting the uid?
>  >
>  > John
>  >
>
> _______________________________________________
>  Camping-list mailing list
>  Camping-list@...
>  http://rubyforge.org/mailman/listinfo/camping-list
>
Jonas Pfenniger | 12 Mar 11:17 2008
Picon

Re: Camping is a winner at SXSW-i

Brilliant !

--

-- 
Cheers,
  Jonas
Jonas Pfenniger | 12 Mar 11:28 2008
Picon

Re: how to "encrypt" the password/login for the blog.rb example?

2008/2/25, Albert Ng <twinwing@...>:
> I'll keep that in mind.
>
> As an aside, using this gem, how would I go about changing the user without
> closing the browser or raising Ā«UnauthorizedĀ»?  That last pops up a log-in
> window that can't authorize (have to press escape).

There is no perfect solution. Here is what I use in jQuery :

// idea from : http://nanodocumet.homedns.org/rest/
  $('#header A.disconnect').click(function() {
    try {
      if ($.browser.msie) {
        // IE clear HTTP Authentication
        document.execCommand("ClearAuthenticationCache");
      } else {
        var xhr = new XMLHttpRequest();
        xhr.open("GET", "/logout", true, "logout", "logout");
        xhr.send(null);
        xhr.abort();
      }
    } catch(e) { error(e) }
  })

---------

* the /logout url should respond "Unauthorized" for the logout:logout credential
* the xhr.open is called with async to true, otherwise the browser
shows the login window

--

-- 
Cheers,
  Jonas
Jonas Pfenniger | 12 Mar 17:58 2008
Picon

Are we ready for a release ?

Hi campers,

what do you think of releasing the current trunk as camping-1.6 ?
Nothing much has moved since a while and apart from FastCGI, I believe
most bugs where ironed out.

After the gem release, I propose putting some effort on documentation
and how to use Rack's FastCGI. When that's done, we'll have a
Rubyforge announcement and such.

/me is waiting for community input

--

-- 
Cheers,
  Jonas

Gmane