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

force git shell user password not to expire #121

Open
epcim opened this issue May 10, 2016 · 2 comments
Open

force git shell user password not to expire #121

epcim opened this issue May 10, 2016 · 2 comments

Comments

@epcim
Copy link
Collaborator

epcim commented May 10, 2016

At:
https://github.com/atomic-penguin/cookbook-gitlab/blob/ae4ee230be9b05228e64959d6788b31b468a48be/recipes/default.rb#L53

execute "#{username}: disable password expiration" do
  #command "chage -M -1 '#{username}'"
  command "chage --lastday 0 --expiredate -1 --inactive -1 --mindays 0 --maxdays 99999 --warndays 7 #{username}"
  only_if do
    require 'shadow'
    Shadow::Passwd.getspnam(username).sp_max != -1 }
  end
end
@epcim
Copy link
Collaborator Author

epcim commented May 10, 2016

any comments on this approach?
any better way to control user shadow attributes in chef (as found user resource do not support them)

@chewi
Copy link
Collaborator

chewi commented Jul 25, 2016

I wrote an LWRP for this ages ago. I could publish it but why is this needed? I don't think you should set a password on that account to start with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants