-
-
Notifications
You must be signed in to change notification settings - Fork 223
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
Add ability to read YAML from stdin to all create
commands
#741
Comments
I'd like to work on this issue, can it be assigned to me please! |
sure, done! |
Where can I find valid example |
@awalvie If i read the docs correctly, it displays all information there is about the entity. This object then could be the source of truth to base all possible config keys from. From my testing, it looks like, it is not implemented in every |
Maybe we could add minimal example configs for each resource to the docs? In much the same way the kubernetes docs do? For example: |
In general, the same data as you get from the matching |
https://linuxcontainers.org/incus/docs/main/rest-api-spec/ This has example values for all the objects, it's not the best looking thing ever but it doesn't need to be manually updated. |
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
@stgraber |
@awalvie the user would still provide the instance and snapshot names but there can still be modifiable fields within a snapshot (see InstanceSnapshotPut), currently that's just the expiry date (ExpiresAt). |
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of lxc#741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
@stgraber are there any configuration options for PS. Could we check off other items from the original list please! Easier to keep track on what's been done :p |
That one is indeed a file API so no struct, stdin should be the file we upload instead. |
It doesn't seem to follow the same pattern of embedding though. In this case |
I'm confused, the exact same is true of InstanceSnapshot embedding InstanceSnapshotPut, am I missing something? |
@awalvie any luck with that last one? |
Sorry about the delay, was out on vacation the past week, I'll get back here shortly! |
Oh, yup, my bad, the way I phrased it was unclear. In the current incus/cmd/incus/storage_volume.go Line 2337 in 7391420
We create a If I do read the data from stdin into an object of the type |
Closes lxc#741 Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
#891 is basically a copy/paste from |
Closes lxc#741 Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Oh, yeah, I see it now. My brain got confused for some reason. Thank You! |
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
`incus network acl create` already has support for creation from a yaml configuration file, but the same wasn't printed in the usage information of the command. This commit updates `incus network acl create` to show example text for `incus network acl create` Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
incus network forward create` already has support for creation from a yaml configuration file, but the same wasn't printed in the usage information of the command. This commit updates `incus network forward create` to include an example Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
incus storage bucket create already has support for creation from a yaml configuration file, but the same wasn't printed in the usage information of the command. This commit updates `incus storage bucket create` to include an example. Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
incus network peer create already has support for creation from a yaml configuration file, but the same wasn't printed in the usage information of the command. This commit updates `incus network peer create` to include an example. Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Part of #741 Signed-off-by: Vishesh Agrawal <agrawal.vishesh.178@gmail.com>
Closes #741 Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Currently only
incus create
andincus launch
will read YAML data from stdin to create a new instance (reading an InstancePut which gets embeded in the InstancePost struct).The same logic should be supported for all other
create
commands:That list was based from a quick grep + some hand filtering, so there may be some entries where reading from stdin doesn't make sense.
The text was updated successfully, but these errors were encountered: