Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Windows support to user.present state function #38563

Open
twangboy opened this issue Jan 4, 2017 · 4 comments
Open

Improve Windows support to user.present state function #38563

twangboy opened this issue Jan 4, 2017 · 4 comments
Assignees
Labels
Feature new functionality including changes to functionality and code refactors, etc. Windows
Milestone

Comments

@twangboy
Copy link
Contributor

twangboy commented Jan 4, 2017

Feature request to add the ability to set the password to never expire from a state along with other Windows specific option.

Make the parameters for user.update available in user.add.

#38544

@twangboy twangboy added Feature new functionality including changes to functionality and code refactors, etc. TEAM Platform labels Jan 4, 2017
@twangboy twangboy added this to the Nitrogen 2 milestone Jan 4, 2017
@twangboy twangboy self-assigned this Jan 4, 2017
@twangboy twangboy changed the title Improve Windows support to user state function Improve Windows support to user.add state function Jan 4, 2017
@twangboy twangboy changed the title Improve Windows support to user.add state function Improve Windows support to user.present state function Jan 5, 2017
@meggiebot meggiebot modified the milestones: Nitrogen 3, Nitrogen 2 Jan 18, 2017
@meggiebot meggiebot modified the milestones: Nitrogen 4, Nitrogen 3 Feb 6, 2017
@Ch3LL Ch3LL modified the milestones: Nitrogen 5, Nitrogen 4 Feb 27, 2017
@rallytime rallytime modified the milestones: Nitrogen 5, Approved Aug 30, 2017
@stale
Copy link

stale bot commented Dec 24, 2018

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.

@stale stale bot added the stale label Dec 24, 2018
@stale stale bot closed this as completed Jan 1, 2019
@henrikor
Copy link

henrikor commented May 4, 2020

Did this ever get implemented? I get "ERROR executing 'state.apply': 'password_never_expires' is an invalid keyword argument for 'user.present'" when trying to use it.

If it's only me doing it wrong - I can't find it documented in: https://docs.saltstack.com/en/latest/ref/states/all/salt.states.user.html

If it's not implemented - it would be nice to get it implemented :-)

@bsoldhogg
Copy link

bsoldhogg commented May 8, 2020

Yeah I'm not seeing this as implemented in 3000. If I run a simple user.present:

local_admin:
  user.present:
    - name: myadmin
    - groups:
      - Administrators
      - Users
    - fullname: Admin

It returns:

ID: local_admin
    Function: user.present
        Name: myadmin
      Result: True
     Comment: New user myadmin created
     Started: 10:54:20.554344
    Duration: 348.091 ms
     Changes:
              ----------
              account_disabled:
                  False
              account_locked:
                  False
              active:
                  True
              comment:
              description:
              disallow_change_password:
                  False
              expiration_date:
                  2106-02-07 06:28:15
              expired:
                  True
              failed_logon_attempts:
                  0
              fullname:
                  Admin
              gid:
              groups:
                  - Administrators
                  - Users
              home:
              homedrive:
              last_logon:
                  Never
              logonscript:
              name:
                  myadmin
              passwd:
                  None
              password_changed:
                  2020-05-08 10:54:20
              password_never_expires:
                  False
              profile:
                  None
              successful_logon_attempts:
                  0
              uid:
                  uid

But adding password_never_expires causes the state to fail:

ERROR executing 'state.apply': 'password_never_expires' is an invalid keyword argument for 'user.present'

@twangboy

@hemantaltair
Copy link

It's not implemented I am getting same error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature new functionality including changes to functionality and code refactors, etc. Windows
Projects
None yet
Development

No branches or pull requests

8 participants