Everything is done through the web (TTW) using the Zope Management Interface (ZMI), so you'll need to be an administrator.
Add the following script to your Plone instance and give the script a name, I called mine 'addusers'.
out = [] |
Note: the use of the role 'trainee' in my example, the role MUST exist for this to work. Also for the Python purists, that "hanging" return statement is perfectly fine, TTW Python scripts run inside Zope and return the output to your browser. If it absolutely bothers you, you can leave it out.
Under the ZMI > properties' add a 'lines' field called 'temp' it should include the usernames and passwords of the newusers (no spaces after the commas)
The 'temp' lines field should look like this:
Running the 'addusers' script will now create the users with the passwords that you defined.The 'temp' lines field should look like this:
Maurice,dttrrrsffd
Natalie,55542yylrw
Herman,d5rrrrr6tfdsa
Ryan,r4rffd243faz
Patrick,e443rereew
Sean,erserwrew
Michael,4343243qw
Update: July 1, 2013
There are a couple other tools mentioned in the comments of this post which you may also want to look at.
https://pypi.python.org/pypi/atreal.usersinout/
http://plone.org/products/collective.mass_subscriptions - can send out initial passwords in bulk
https://pypi.python.org/pypi/collective.loremipsum - generates fake content and fake users
5 comments:
https://pypi.python.org/pypi/atreal.usersinout/ ?
:) thanks Christian. Will look into that addon.
If you need to send e-mail after creation or auto-generate starting password: http://plone.org/products/collective.mass_subscriptions
Or you can just use collective.loremipsum to create 500 users with data generated from http://fakenamegenerator.com :)
Might also be useful: http://play.pixelblaster.ro/blog/archive/2011/03/09/export-import-users-in-and-out-of-plone
Post a Comment