Skip to content

Commit

Permalink
swapping cr and crbs to r and rbs
Browse files Browse the repository at this point in the history
Signed-off-by: greg pereira <grpereir@redhat.com>
  • Loading branch information
Gregory-Pereira authored and JasonPowr committed Apr 22, 2024
1 parent 383042c commit 3aa5393
Show file tree
Hide file tree
Showing 23 changed files with 205 additions and 93 deletions.
2 changes: 1 addition & 1 deletion api/v1alpha1/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ type ExternalAccess struct {
type MonitoringConfig struct {
// If true, the Operator will create monitoring resources
//+kubebuilder:validation:XValidation:rule=(self || !oldSelf),message=Feature cannot be disabled
//+kubebuilder:default:=false
//+kubebuilder:default:=true
Enabled bool `json:"enabled"`
}

Expand Down
2 changes: 1 addition & 1 deletion api/v1alpha1/fulcio_types_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ var _ = Describe("Fulcio", func() {
validObject.Spec.Config.MetaIssuers = []OIDCIssuer{
{
ClientID: "client",
Type: "email",
Type: "email",
},
}

Expand Down
4 changes: 0 additions & 4 deletions api/v1alpha1/securesign_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@ type SecuresignSpec struct {
Rekor RekorSpec `json:"rekor,omitempty"`
Fulcio FulcioSpec `json:"fulcio,omitempty"`
Trillian TrillianSpec `json:"trillian,omitempty"`
// If true, the Operator will create segment backup job and cronjob and required RBAC
//+kubebuilder:validation:XValidation:rule=(self || !oldSelf),message=Feature cannot be disabled
//+kubebuilder:default:=false
Analytics bool `json:"analytics"`
//+kubebuilder:default:={keys:{{name: rekor.pub},{name: ctfe.pub},{name: fulcio_v1.crt.pem}}}
Tuf TufSpec `json:"tuf,omitempty"`
Ctlog CTlogSpec `json:"ctlog,omitempty"`
Expand Down
4 changes: 2 additions & 2 deletions bundle/manifests/rhtas-operator.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,15 +101,15 @@ metadata:
"enabled": true
},
"monitoring": {
"enabled": false
"enabled": true
}
},
"rekor": {
"externalAccess": {
"enabled": true
},
"monitoring": {
"enabled": false
"enabled": true
}
},
"trillian": {
Expand Down
2 changes: 1 addition & 1 deletion bundle/manifests/rhtas.redhat.com_fulcios.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ spec:
description: Enable Service monitors for fulcio
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring resources
type: boolean
x-kubernetes-validations:
Expand Down
2 changes: 1 addition & 1 deletion bundle/manifests/rhtas.redhat.com_rekors.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ spec:
description: Enable Service monitors for rekor
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring resources
type: boolean
x-kubernetes-validations:
Expand Down
4 changes: 2 additions & 2 deletions bundle/manifests/rhtas.redhat.com_securesigns.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ spec:
description: Enable Service monitors for fulcio
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring
resources
type: boolean
Expand Down Expand Up @@ -441,7 +441,7 @@ spec:
description: Enable Service monitors for rekor
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring
resources
type: boolean
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rhtas.redhat.com_ctlogs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ spec:
description: Enable Service monitors for ctlog
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring resources
type: boolean
x-kubernetes-validations:
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rhtas.redhat.com_fulcios.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ spec:
description: Enable Service monitors for fulcio
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring resources
type: boolean
x-kubernetes-validations:
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rhtas.redhat.com_rekors.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ spec:
description: Enable Service monitors for rekor
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring resources
type: boolean
x-kubernetes-validations:
Expand Down
18 changes: 4 additions & 14 deletions config/crd/bases/rhtas.redhat.com_securesigns.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,22 +56,14 @@ spec:
spec:
description: SecuresignSpec defines the desired state of Securesign
properties:
analytics:
default: false
description: If true, the Operator will create segment backup job
and cronjob and required RBAC
type: boolean
x-kubernetes-validations:
- message: Feature cannot be disabled
rule: (self || !oldSelf)
ctlog:
description: CTlogSpec defines the desired state of CTlog component
properties:
monitoring:
description: Enable Service monitors for ctlog
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring
resources
type: boolean
Expand Down Expand Up @@ -371,7 +363,7 @@ spec:
description: Enable Service monitors for fulcio
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring
resources
type: boolean
Expand Down Expand Up @@ -443,7 +435,7 @@ spec:
description: Enable Service monitors for rekor
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring
resources
type: boolean
Expand Down Expand Up @@ -641,7 +633,7 @@ spec:
description: Enable Monitoring for Logsigner and Logserver
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring
resources
type: boolean
Expand Down Expand Up @@ -723,8 +715,6 @@ spec:
minimum: 1
type: integer
type: object
required:
- analytics
type: object
status:
description: SecuresignStatus defines the observed state of Securesign
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rhtas.redhat.com_trillians.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ spec:
description: Enable Monitoring for Logsigner and Logserver
properties:
enabled:
default: false
default: true
description: If true, the Operator will create monitoring resources
type: boolean
x-kubernetes-validations:
Expand Down
11 changes: 11 additions & 0 deletions config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,14 @@ rules:
- patch
- update
- watch
- apiGroups:
- monitoring.coreos.com
resources:
- prometheuses/api
verbs:
- create
- get
- update
- apiGroups:
- monitoring.coreos.com
resources:
Expand Down Expand Up @@ -233,6 +241,7 @@ rules:
verbs:
- create
- delete
- deletecollection
- get
- list
- patch
Expand All @@ -245,6 +254,7 @@ rules:
verbs:
- create
- delete
- deletecollection
- get
- list
- patch
Expand All @@ -257,6 +267,7 @@ rules:
verbs:
- create
- delete
- deletecollection
- get
- list
- patch
Expand Down
7 changes: 4 additions & 3 deletions config/samples/rhtas_v1alpha1_securesign.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ metadata:
app.kubernetes.io/name: securesign-sample
app.kubernetes.io/instance: securesign-sample
app.kubernetes.io/part-of: trusted-artifact-signer
annotations:
rhtas.redhat.com/metrics: "false"
name: securesign-sample
namespace: rhtas-operator
spec:
rekor:
externalAccess:
enabled: true
monitoring:
enabled: false
enabled: true
trillian:
database:
create: true
Expand All @@ -30,7 +31,7 @@ spec:
organizationEmail: jdoe@redhat.com
commonName: fulcio.hostname
monitoring:
enabled: false
enabled: true
tuf:
externalAccess:
enabled: true
Expand Down

0 comments on commit 3aa5393

Please sign in to comment.