2019-07-17 17:53:13 -07:00
|
|
|
package annotations
|
|
|
|
|
|
|
|
const annotationQueueName = "annotation-queue"
|
|
|
|
const workerThreadCount = 1
|
2019-07-24 14:25:28 -04:00
|
|
|
const workQueueRetryLimit = 5
|
2019-07-17 17:53:13 -07:00
|
|
|
|
2019-07-19 15:10:40 -07:00
|
|
|
func getStatus(status bool) string {
|
|
|
|
if status {
|
|
|
|
return "Success"
|
|
|
|
}
|
|
|
|
return "Failure"
|
2019-07-17 17:53:13 -07:00
|
|
|
}
|
|
|
|
|
2019-07-19 15:10:40 -07:00
|
|
|
func BuildKey(policyName string) string {
|
2019-07-24 14:25:28 -04:00
|
|
|
//JSON Pointers
|
|
|
|
return "policies.kyverno.io~1" + policyName
|
2019-07-17 17:53:13 -07:00
|
|
|
}
|
2019-07-25 13:14:55 -04:00
|
|
|
|
|
|
|
func BuildKeyString(policyName string) string {
|
|
|
|
return "policies.kyverno.io/" + policyName
|
|
|
|
}
|