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

🌠 V9 #712

Merged
merged 8 commits into from
Sep 11, 2023
Merged

🌠 V9 #712

merged 8 commits into from
Sep 11, 2023

Conversation

arlimus
Copy link
Member

@arlimus arlimus commented Sep 5, 2023

This is one of the biggest updates to cnspec since we first released it!

It uses v9 of cnquery, which provides modular provider plugins which gives 3 big advantages:

  1. The binaries are 90% smaller, from 277mb => 30mb, i.e. 90% reduction in size
  2. Both cnquery and cnspec share the same providers, so no more duplication, i.e. another 50% smaller
  3. You can now write your own providers! They are not mandatory to be in our managed repo anymore. In fact, as long as you adhere to the same interface (which is Terraform plugin) you can write providers in any language and even keep them internal (which for some custom systems is incredibly useful). Of course we ♥️ providers so feel free to add suggestions and things you'd love to see.

Checklist of related PRs:

The os provider may not exist on the run or on the system. In these cases, the method to determine the datapoint for vulnerability report or kernel info will fail. To better handle these errors, we abandon the previous approach of `MustGetOneDatapoint` via `MustCompile` and instead use the provider info to report back to users.

There may still be other reasons why the compile fails, but we will keep this focused on the primary reason in a tested environment with a working provider runtime that indicates why this fails: no provider for this code.

Signed-off-by: Dominik Richter <[email protected]>
1. double-check that elements exist with a require call (to avoid nil panics)
2. checksums changed because `asset{*}` is different for v9 (since fields were changed in this resource)

Signed-off-by: Dominik Richter <[email protected]>
Signed-off-by: Dominik Richter <[email protected]>
Signed-off-by: Dominik Richter <[email protected]>
Copy link
Member

@chris-rock chris-rock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wooot

@arlimus arlimus changed the title V9 🌠 V9 Sep 11, 2023
@arlimus arlimus merged commit 82bb062 into main Sep 11, 2023
8 checks passed
@arlimus arlimus deleted the v9 branch September 11, 2023 00:09
@github-actions github-actions bot locked and limited conversation to collaborators Sep 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants