mirror of
https://github.com/kubescape/kubescape.git
synced 2026-04-10 04:36:52 +00:00
Also: * declared scanner resources as an enum type * replaced stdlib json, added uit tests for skipped resources * unexported worker pool * more unexported methods (i.e. everything that is not part of the interface) * refact(core): clarified mock injection logic and added a few unit tests at the caller's (CLI init utils) Signed-off-by: Frederic BIDON <fredbi@yahoo.com>
Kubescape core package
// initialize kubescape
ks := core.NewKubescape()
// scan cluster
results, err := ks.Scan(&cautils.ScanInfo{})
// convert scan results to json
jsonRes, err := results.ToJson()