-
Notifications
You must be signed in to change notification settings - Fork 24
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
neonvm: add readiness probe for sysfs scaling #1190
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,6 +29,7 @@ kind: VirtualMachine | |
metadata: | ||
name: example | ||
spec: | ||
cpuScalingMode: SysfsScaling | ||
guest: | ||
cpus: | ||
min: 1 | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
::sysinit:/neonvm/bin/vminit | ||
::once:/neonvm/bin/touch /neonvm/vmstart.allowed | ||
::respawn:/neonvm/bin/neonvmd --addr=0.0.0.0:25183 | ||
::respawn:/neonvm/bin/udhcpc -t 1 -T 1 -A 1 -f -i eth0 -O 121 -O 119 -s /neonvm/bin/udhcpc.script | ||
::respawn:/neonvm/bin/udevd | ||
::wait:/neonvm/bin/udev-init.sh | ||
::respawn:/neonvm/bin/acpid -f -c /neonvm/acpi | ||
::respawn:/neonvm/bin/vector -c /neonvm/config/vector.yaml --config-dir /etc/vector --color never | ||
::respawn:/neonvm/bin/chronyd -n -f /neonvm/config/chrony.conf -l /var/log/chrony/chrony.log | ||
::respawn:/neonvm/bin/sshd -E /var/log/ssh.log -f /neonvm/config/sshd_config | ||
::respawn:/neonvm/bin/neonvmd --addr=0.0.0.0:25183 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. question: Why this change? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh, I thought I covered it in the PR description. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. IIUC then, the idea behind moving neonvmd down is to give other daemons a chance to start first, right? Is that actually guaranteed? |
||
::respawn:/neonvm/bin/vmstart | ||
{{ range .InittabCommands }} | ||
::{{.SysvInitAction}}:su -p {{.CommandUser}} -c {{.ShellEscapedCommand}} | ||
|
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.
question: Is there a difference between
== nil
vslen(...) == 0
? I was a little surprised to see this check on a sliceThere 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 right, I don't think there is any difference for a slice if we use
== nil
orlen(...) == 0
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.
nil slices and non-nil empty slices are two different things: https://go.dev/play/p/UtIWK670wxW
I always use
len(...) == 0
to cover both cases.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.
I usually tend use != nil or len(slice) depending on the semantics of a particular code (like if I am interested in length or emptiness for sure) but I am ok with using any option here.