mirror of
https://github.com/kyverno/policy-reporter.git
synced 2024-12-14 11:57:32 +00:00
source attribute added to report.
Signed-off-by: Nikolay Osmolovskiy <nikolay.osmolovsky@gmail.com>
This commit is contained in:
parent
421cdadbc6
commit
1ed28a5d9f
2 changed files with 2 additions and 0 deletions
|
@ -32,4 +32,5 @@ type Result struct {
|
||||||
Properties map[string]string `json:"properties,omitempty"`
|
Properties map[string]string `json:"properties,omitempty"`
|
||||||
Resource Resource `json:"resource"`
|
Resource Resource `json:"resource"`
|
||||||
CreationTimestamp time.Time `json:"creationTimestamp"`
|
CreationTimestamp time.Time `json:"creationTimestamp"`
|
||||||
|
Source string `json:"source"`
|
||||||
}
|
}
|
||||||
|
|
|
@ -75,6 +75,7 @@ func NewJSONResult(r v1alpha2.PolicyReportResult) Result {
|
||||||
Properties: r.Properties,
|
Properties: r.Properties,
|
||||||
Resource: res,
|
Resource: res,
|
||||||
CreationTimestamp: time.Unix(r.Timestamp.Seconds, int64(r.Timestamp.Nanos)),
|
CreationTimestamp: time.Unix(r.Timestamp.Seconds, int64(r.Timestamp.Nanos)),
|
||||||
|
Source: r.Source,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue