noisebridge / pyclass-project

Other
8 stars 2 forks source link

Create templates for user registration #7

Closed Belgand closed 12 years ago

Belgand commented 12 years ago

There are a bunch of these and they're going to take a bit of work to get all of the relevant bits in. Check out the list at: http://docs.b-list.org/django-registration/0.8/quickstart.html they're at the bottom under Required Templates.

gmckeever commented 12 years ago

Hey Mark,

I had guests in town and didn't really have time to start this until Monday. I gave django-guardian a shot instead of registration but I don't think I install it correctly. I forgot how Elizabeth installed it so I just went with the documentation and used pip https://github.com/lukaszb/django-guardian . Did you get a module installed? Also, are you going to be at noisebridge tonight or just Thursday? I will be near noisebrige tonight so I can always go there after 8.

On Apr 19, 2012, at 10:13 AM, Mark Smith wrote:

There are a bunch of these and they're going to take a bit of work to get all of the relevant bits in. Check out the list at: http://docs.b-list.org/django-registration/0.8/quickstart.html they're at the bottom under Required Templates.


Reply to this email directly or view it on GitHub: https://github.com/noisebridge/pyclass-project/issues/7

Belgand commented 12 years ago

Yeah, I installed it and pushed it back up to the repo last week. I won't be there tonight because of a prior engagement, but I will be there on Thursday to talk about it. Basically the key thing is to not use pip, but add it to buildout.cfg and then re-reun buildout.

So you'd want to edit buildout.cfg to:

eggs = noisebridge.pyclass
       django-registration
       django-guardian

then just run

python bootstrap.py
./bin/buildout 

again and it should pull down and install any packages you added into the virtual environment that buildout creates. You just need to add the name of the package too, it'll do the necessary searching for you on PyPi and, IIRC, probably some other places.

That way not only is it safely installed in the sandbox, but it's set up to install whenever someone runs buildout. Most likely you just installed it locally and system-wide. After that it's just a matter of configuring it to work with our code.

Personally I didn't quite see what guardian was really adding that we didn't already have. It looks like it adds greater ability to assign permissions for classes to particular user groups, but I'd really need to drill down into the existing permissions to understand why it was necessary to extend them and whether we'd need to or not.

One of my biggest concerns with registration was that we'd need to hook it into a mail server and that could be messy. Especially during development (where I was thinking of setting it up to ignore the e-mail step for ease-of-use). What we might want to focus on is adding in support for another authorization backend (e.g. OpenID), but either way it's something we should talk about as a group on Thursday.

Belgand commented 12 years ago

Greg updated it with templates found at: https://bitbucket.org/lzantal/django-registration-templates/ and as far as we can tell they work. We won't have more info until we get authorization going.