Skip to content
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

Epic: Standard interface for running containers AND/OR systemd services in VMs #835

Open
3 tasks
sharnoff opened this issue Feb 27, 2024 · 0 comments
Open
3 tasks
Labels
c/autoscaling/neonvm Component: autoscaling: NeonVM t/Epic Issue type: Epic

Comments

@sharnoff
Copy link
Member

Split off from #577.

Motivation

  • vm-builder must make hacky modifications to files (see e.g. /neonvm/bin/...) to avoid conflicting with the root filesystem supplied by the user's image
  • the "image spec" yaml file is hacky, dockerfile-in-yaml with a separate "merge" step to combine images into a single root filesystem
  • it's currently difficult to limit CPU usage of postgres inside the VM
  • logs routing is annoying, and maybe systemd can help here; see Epic: Separately tagged logs for VM processes, dmesg, and runner  #578
  • if a user breaks out of postgres, they can freely disrupt neonvm internal programs running in the VM

DoD

  1. Use systemd services and/or containers to run programs inside the VM
  2. Maybe expose separate configuration for these in the VM spec, to allow easier parameterization by control plane
  3. Maybe allow "delayed start" so e.g. compute_ctl can start a daemon-ish program only after a certain point.

Implementation ideas

There's kind of two approaches we've discussed for the internal details:

  1. Via containers running inside the VM
    • i.e.: vm-builder loads docker images, exports to tarball, unpacks into VM image; on startup, we use e.g. runc to run the images stored there
  2. Via systemd "services"

We also could use some combination of the two, e.g. using systemd to runc run the containers as a service. We also discussed that systemd maybe has a way to run containers natively? also an option.

Tasks

Tasks

Preview Give feedback

Other related tasks, Epics, and links

@sharnoff sharnoff added t/Epic Issue type: Epic c/autoscaling/neonvm Component: autoscaling: NeonVM labels Feb 27, 2024
@sharnoff sharnoff mentioned this issue Feb 27, 2024
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c/autoscaling/neonvm Component: autoscaling: NeonVM t/Epic Issue type: Epic
Projects
None yet
Development

No branches or pull requests

1 participant