You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
OmniDB offers a few command line commands to manage creation of users in particular, like -u or -s.
There is no command line available to generate a new password for an existing user (when they forget it), and that would be needed when using Ansible automation (which is our case) to manage OmniDB users and associated DB connections.
This kind of command line feature would be really appreciated :-)
I would see something like that: maybe add this piece of code in omnidb-server.py:
group.add_option("-up", "--userpwd", dest="userpwd",
nargs=2,metavar="username password",
help="update user password: -up username password")
group.add_option("-sp", "--superuserpwd", dest="superuserpwd",
nargs=2,metavar="username password",
help="update super user password: -sp username password")
Then code the needed functions to handle those two new command line options, for example:
def user_pwd(p_user,p_pwd,p_superuser):
User.objects.get(username=p_user).set_password(p_pwd)
if options.userpwd:
maintenance_action = True
user_pwd(options.userpwd[0], options.userpwd[1], False)
if options.superuserpwd:
maintenance_action = True
user_pwd(options.superuserpwd[0], options.superuserpwd[1], True)
Well in fact I don't really know because I'm not a Python developer :-(
Best regards.
The text was updated successfully, but these errors were encountered:
Hello,
OmniDB offers a few command line commands to manage creation of users in particular, like -u or -s.
There is no command line available to generate a new password for an existing user (when they forget it), and that would be needed when using Ansible automation (which is our case) to manage OmniDB users and associated DB connections.
This kind of command line feature would be really appreciated :-)
I would see something like that: maybe add this piece of code in omnidb-server.py:
Then code the needed functions to handle those two new command line options, for example:
Well in fact I don't really know because I'm not a Python developer :-(
Best regards.
The text was updated successfully, but these errors were encountered: