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

Conversation

Projects
None yet
4 participants
@chris-rock
Collaborator

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'

@binamov binamov added the in progress label Nov 4, 2016

enable chef-server fetcher attribute
Signed-off-by: Christoph Hartmann <chris@lollyrock.com>
@vjeffrey

This comment has been minimized.

Show comment
Hide comment
@vjeffrey

vjeffrey Nov 4, 2016

Collaborator

🌟 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

Collaborator

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

This comment has been minimized.

Show comment
Hide comment
@sc0ttruss

sc0ttruss 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"

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

This comment has been minimized.

Show comment
Hide comment
@chris-rock

chris-rock Nov 4, 2016

Collaborator

Thanks @vjeffrey and @sc0ttruss for testing

Collaborator

chris-rock commented Nov 4, 2016

Thanks @vjeffrey and @sc0ttruss for testing

@chris-rock chris-rock merged commit 8923fc9 into master Nov 4, 2016

2 checks passed

DCO This commit has a DCO Signed-off-by
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@chris-rock chris-rock deleted the chris-rock/chef-fetcher branch Nov 4, 2016

@binamov binamov removed the in progress label Nov 4, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment