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

enable chef-server fetcher attribute #145

Merged
merged 1 commit into from Nov 4, 2016
Merged

Conversation

chris-rock
Copy link
Contributor

@chris-rock chris-rock commented Nov 4, 2016

This allows users to enable the chef-server fetcher with another reporter, e.g. Visibility

Just set the attribute default['audit']['fetcher'] = 'chef-server'

Signed-off-by: Christoph Hartmann <chris@lollyrock.com>
@vjeffrey
Copy link

vjeffrey commented Nov 4, 2016

🌟 so much awesomenesssssss....i haven't tested, but it's pretty straightforward. i'll test in a bit if no one gets to it before me

@sc0ttruss
Copy link

sc0ttruss commented Nov 4, 2016

Tested this locally with 9 nodes, used the following role to test whilst, setting the following two lines in the nodes client.rb. Able to see data in both compliance and in visibility. Timestamps in both confirm they come from the same origin.
Output: Major, 58, Minor, 14, Compliant 26, skipped 1, critical 8, - Chef Automate

Whilst it works in automate, and the data seems complete. In Compliance, the timestamp is correct on the "dashboard" screen ( 17:37 in this case ), but once clicked on the node (scan) in the dashboard, the data is from the previous scan ( 17:11 ). So, something amiss on the compliance front, unless I have misconfigured something there. Will check further but update for now.

{
  "name": "audit",
  "chef_tupe": "role",
  "json_class": "Chef::Role",
  "default_attributes": {
    "audit": {
      "profiles": [
      {
        "name": "ssh",
        "compliance": "base/ssh"
      },
      {
        "name": "linux",
        "compliance": "base/linux"
      }
    ],
     "collector": ["chef-visibility","chef-server"]
    }
  }
}

and client.rb has the two lines added :note change the hostname if you are copying and the token is the default token for automate.

data_collector.server_url "https://automate.myorg.chefdemo.net/data-collector/v0/"
data_collector.token "93a49a4f2482c64126f7b6015e6b0f30284287ee4054ff8807fb63d9cbd1c506"

@chris-rock
Copy link
Contributor Author

Thanks @vjeffrey and @sc0ttruss for testing

@chris-rock chris-rock merged commit 8923fc9 into master Nov 4, 2016
@chris-rock chris-rock deleted the chris-rock/chef-fetcher branch November 4, 2016 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants