-
Notifications
You must be signed in to change notification settings - Fork 133
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
kvm/qemu mounting #598
kvm/qemu mounting #598
Conversation
f9e603d
to
ef536ff
Compare
`ops volume attach` lets user attach volume to a stopped instance. as of this commit, `ops run` overwrite this config though. `ops run --mounts` lets user mount volume to an instance on run, but does not persist the config. as of this commit, changes made to volume during run is visible, but gets discarded on subsequent run without `--skipbuild`
ef536ff
to
c38b78d
Compare
|
||
// saveImageConfig saves image config as JSON | ||
// for volume attach/detach purposes | ||
func saveImageConfig(c Config) error { |
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 is fine for now but something we should prob. fix in the future - a good chunk of the variables being stored here are dynamic in nature and don't belong here;
also - 'manifests' have an inherent meaning already and probably wise to change this to a different phrase
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'd dbl chk that dupe comment && might be worth adding a test of some kind but otherwise we can merge
lepton/manifest.go
Outdated
} | ||
|
||
var vmpath string | ||
if hostpath[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.
dupe? not needed
merging since original comments were fixed && i've created tkts for the other issues and this has been sitting for a few weeks now |
RFC
JSON
store to keep track of created volumes, maybe use some more established KV store?ops volume create
to create volume is necessary before runningops run --mounts <uuid:mount_path>
sinceUUID
is necessary. my idea is that when user wants to mount on run, they could perhaps just providehost_path
and that new volume will be created and attached on the fly?sample usage can be seen at ronaudinho/ops-examples@722fff5
(i tested
JSON
read/write, but on write,json.Unmarshal
result is weird, so i do not call it in the main)references
TODO