-
Notifications
You must be signed in to change notification settings - Fork 2
fix(ci): fix mirrord health probes and certificate paths #1547
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
Open
loktev-d
wants to merge
1
commit into
main
Choose a base branch
from
fix/ci/mirrord-probe-and-cert-paths
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Daniil Loktev <[email protected]>
Reviewer's guide (collapsed on small PRs)Reviewer's GuideThis PR enhances the mirrord-based CI setup by setting a dedicated TMPDIR, correcting certificate path typos in flag definitions, and stripping health probes from mirrored deployments. Flow diagram for mirrord.sh deployment mirroring processflowchart TD
A["Original Deployment"] -->|"Check if Mirrored Deployment Exists"| B{"Mirrored Deployment Exists?"}
B -- No --> C["Create Mirrored Deployment"]
C --> D["Set container image to alpine:3.20.1"]
D --> E["Remove livenessProbe"]
E --> F["Remove readinessProbe"]
F --> G["Set labels: mirror=true, ownerName"]
B -- Yes --> H["Skip creation"]
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.
Hey there - I've reviewed your changes and they look great!
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location> `images/virtualization-artifact/Taskfile.yaml:95-96` </location>
<code_context>
flags+=( "--kubevirt-cabundle=/etc/virt-api/certificates/ca.crt" )
flags+=( "--kubevirt-endpoint=virt-api.{{ .BaseNamespace }}.svc" )
flags+=( "--secure-port=8443" )
- flags+=( "--tls-private-key-file=/etc/virtualziation-api/certificates/tls.key" )
- flags+=( "--tls-cert-file=/etc/virtualziation-api/certificates/tls.crt" )
+ flags+=( "--tls-private-key-file=/etc/virtualization-api/certificates/tls.key" )
+ flags+=( "--tls-cert-file=/etc/virtualization-api/certificates/tls.crt" )
flags+=( "--v=7" )
</code_context>
<issue_to_address>
**issue (typo):** Typo correction in path improves reliability.
Correcting the path ensures the application can locate the required certificate files and prevents runtime failures.
```suggestion
flags+=( "--tls-private-key-file=/etc/virtualization-api/certificates/tls.key" )
flags+=( "--tls-cert-file=/etc/virtualization-api/certificates/tls.crt" )
```
</issue_to_address>
### Comment 2
<location> `images/virtualization-artifact/Taskfile.yaml:98-99` </location>
<code_context>
+ flags+=( "--tls-private-key-file=/etc/virtualization-api/certificates/tls.key" )
+ flags+=( "--tls-cert-file=/etc/virtualization-api/certificates/tls.crt" )
flags+=( "--v=7" )
- flags+=( "--proxy-client-cert-file=/etc/virtualziation-api-proxy/certificates/tls.crt" )
- flags+=( "--proxy-client-key-file=/etc/virtualziation-api-proxy/certificates/tls.key" )
+ flags+=( "--proxy-client-cert-file=/etc/virtualization-api-proxy/certificates/tls.crt" )
+ flags+=( "--proxy-client-key-file=/etc/virtualization-api-proxy/certificates/tls.key" )
flags+=( "--service-account-name=virtualization-api" )
</code_context>
<issue_to_address>
**issue (typo):** Typo fix in proxy client cert path prevents misconfiguration.
This spelling correction ensures the proxy client certificate path is valid and prevents referencing a non-existent file.
```suggestion
flags+=( "--proxy-client-cert-file=/etc/virtualization-api-proxy/certificates/tls.crt" )
flags+=( "--proxy-client-key-file=/etc/virtualization-api-proxy/certificates/tls.key" )
```
</issue_to_address>
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Fixed mirrord local development setup for both
virtualization-controller
andvirtualization-api
:Health probes removal: Modified
mirrord.sh
to removelivenessProbe
andreadinessProbe
from the mirrored container (alpine sleepcontainer) to prevent probe failures.
Certificate path fix: Set
TMPDIR=/tmp
in both mirrord tasks to ensureos.TempDir()
returns/tmp
for macOS, matching thecertificate mount path in pods (
/tmp/k8s-webhook-server/serving-certs
).Typo fix: Corrected certificate path typos in apiserver task:
virtualziation
→virtualization
.Why do we need it, and what problem does it solve?
What is the expected result?
Checklist
Changelog entries