-
Notifications
You must be signed in to change notification settings - Fork 23
[SECURESIGN-3179] Updates to use the latest Rekor Monitor #1416
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
base: main
Are you sure you want to change the base?
Conversation
Reviewer's GuideThis PR enhances CRDs with EnvFiles support (fileKeyRef), introduces a ConfigMap-based PVC reference for TUF (with new API fields, constants, and controller action), and updates the Rekor monitor StatefulSet to retrieve and mount the TUF PVC from that ConfigMap while adapting its init container. Sequence diagram for Rekor monitor retrieving and mounting TUF PVC via ConfigMapsequenceDiagram
participant RekorMonitor
participant K8sAPI
participant TUF_PVC_ConfigMap
participant TUF_PVC
RekorMonitor->>K8sAPI: Get TUF_PVC_ConfigMap
K8sAPI-->>RekorMonitor: Return pvcName
RekorMonitor->>K8sAPI: Mount PVC (using pvcName)
K8sAPI-->>RekorMonitor: PVC mounted as /tuf-repository
Entity relationship diagram for updated TUF and Rekor CRDserDiagram
TufStatus {
string PvcName
string Url
LocalObjectReference PvcConfig
}
LocalObjectReference {
string Name
}
TufStatus ||--|{ LocalObjectReference : "pvcConfig"
RekorEnvVarSource {
string key
boolean optional
string path
string volumeName
}
RekorEnvVarSource }|--|| LocalObjectReference : "volumeName"
Class diagram for new and updated TUF controller typesclassDiagram
class TufStatus {
+[]TufKey Keys
+string PvcName
+LocalObjectReference PvcConfig
+string Url
}
class LocalObjectReference {
+string Name
}
TufStatus --> LocalObjectReference : PvcConfig
class pvcConfigAction {
+Name() string
+CanHandle(ctx, instance) bool
+Handle(ctx, instance) *action.Result
}
pvcConfigAction --|> BaseAction
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
|||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
||||||||||||||
3014d45 to
5094224
Compare
dab637e to
d45e786
Compare
| ) | ||
|
|
||
| rekorServerHost := fmt.Sprintf("http://%s.%s.svc", actions.ServerComponentName, instance.Namespace) | ||
| tufServerHost := fmt.Sprintf("http://%s.%s.svc", tufConstants.ComponentName, instance.Namespace) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will be problem, we cannot expect that Rekor server and Tuf server is running in same namespace. We already have test case for it where every main services are running in their separate namespace.
https://github.com/securesign/secure-sign-operator/blob/main/test/e2e/namespaced.go
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you're right! I added TufService and used the same logic as other components.
469531f to
468d8c0
Compare
This PR updates the Rekor monitor to work with the latest Rekor Monitor image and integrate TUF repository awareness and readiness:
Rekor Monitor StatefulSet:
E2E tests:
Images and dependencies:
Overall, it enables cross-component TUF usage by Rekor monitor (waiting for TUF readiness and consuming TUF root), aligns tests with the new behavior, and updates images to the latest versions.