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

chef_user and chef_org load_current_value into node.run_state is not working #236

Open
nicutor opened this issue Nov 7, 2018 · 1 comment

Comments

@nicutor
Copy link

nicutor commented Nov 7, 2018

Cookbook version

2.3.2

Chef-client version

14.6.47

Platform Details

CentOS Linux release 7.4.1708 (Core)

Hi,

I am dealing with some issues when I am using chef_user resource:

  * chef_user[test] action create
    * directory[/etc/opscode/users] action create (up to date)
    * execute[create-user-test] action run (skipped due to not_if)
    * ruby_block[append-user-to-users] action run
      - execute the ruby block append-user-to-users
    * execute[grant-server-admin-test] action run
      - execute chef-server-ctl grant-server-admin-permissions test

ruby_block[append-user-to-users] and execute[grant-server-admin-test] is executed all the time.

Also on chef_org resource:

  * chef_org[test] action create
    * directory[/etc/opscode/orgs] action create (up to date)
    * execute[create-org-test] action run (skipped due to not_if)
    * execute[add-user-test-org-test] action run (skipped due to not_if)
    * execute[add-admin-test-org-test] action run (skipped due to not_if)
     (up to date)

execute[add-user-test-org-test] and execute[add-admin-test-org-test] are always skipped.

From what I can see, the node.run_state is never populated by the load_current_value from these resources.
puts node.run_state shows always an empty hash {}

Can you please check and fix this?

Thank you!

@jingkaihe
Copy link

Running into the same issue

@nicutor it appear to be an issue that exists in 2.3.2 - https://github.com/chef-cookbooks/chef-ingredient/blob/v2.3.2/resources/chef_org.rb#L55-L62

should be addressed in the future release though - #233

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