[Samba] scripting user adds/deletes

Quentin Gibeaux qgibeaux at iris-tech.fr
Wed Jul 23 01:21:30 MDT 2014


On 23/07/2014 08:17, David Bear wrote:
> I'm wanting to build a script that will add and remove or deactivate users.
> My language is python. are there are docs that describe how to use some of
> the python modules to do this?
>
No need to build a script :

root at server:~# samba-tool user
Usage: samba-tool user <subcommand>

User management.


Options:
   -h, --help  show this help message and exit


Available subcommands:
   add          - Create a new user.
   create       - Create a new user.
   delete       - Delete a user.
   disable      - Disable an user.
   enable       - Enable an user.
   list         - List all users.
   password     - Change password for a user account (the one provided 
in authentication).
   setexpiry    - Set the expiration of a user account.
   setpassword  - Set or reset the password of a user account.
For more help on a specific subcommand, please type: samba-tool user 
<subcommand> (-h|--help)


More information about the samba mailing list