()
| 50 | } |
| 51 | |
| 52 | func (c *PluginRuntimeRegisterCommand) Flags() *FlagSets { |
| 53 | set := c.flagSet(FlagSetHTTP) |
| 54 | |
| 55 | f := set.NewFlagSet("Command Options") |
| 56 | |
| 57 | f.StringVar(&StringVar{ |
| 58 | Name: "type", |
| 59 | Target: &c.flagType, |
| 60 | Completion: complete.PredictAnything, |
| 61 | Usage: "Plugin runtime type. Vault currently only supports \"container\" runtime type.", |
| 62 | }) |
| 63 | |
| 64 | f.StringVar(&StringVar{ |
| 65 | Name: "oci_runtime", |
| 66 | Target: &c.flagOCIRuntime, |
| 67 | Completion: complete.PredictAnything, |
| 68 | Usage: "OCI runtime. Default is \"runsc\", gVisor's OCI runtime.", |
| 69 | }) |
| 70 | |
| 71 | f.StringVar(&StringVar{ |
| 72 | Name: "cgroup_parent", |
| 73 | Target: &c.flagCgroupParent, |
| 74 | Completion: complete.PredictAnything, |
| 75 | Usage: "Parent cgroup to set for each container. This can be used to control the total resource usage for a group of plugins.", |
| 76 | }) |
| 77 | |
| 78 | f.Int64Var(&Int64Var{ |
| 79 | Name: "cpu_nanos", |
| 80 | Target: &c.flagCPUNanos, |
| 81 | Completion: complete.PredictAnything, |
| 82 | Usage: "CPU limit to set per container in nanos. Defaults to no limit.", |
| 83 | }) |
| 84 | |
| 85 | f.Int64Var(&Int64Var{ |
| 86 | Name: "memory_bytes", |
| 87 | Target: &c.flagMemoryBytes, |
| 88 | Completion: complete.PredictAnything, |
| 89 | Usage: "Memory limit to set per container in bytes. Defaults to no limit.", |
| 90 | }) |
| 91 | |
| 92 | f.BoolVar(&BoolVar{ |
| 93 | Name: "rootless", |
| 94 | Target: &c.flagRootless, |
| 95 | Completion: complete.PredictAnything, |
| 96 | Usage: "Whether the container runtime is configured to run as a " + |
| 97 | "non-privileged (non-root) user. Required if the plugin container " + |
| 98 | "image is also configured to run as a non-root user.", |
| 99 | }) |
| 100 | |
| 101 | return set |
| 102 | } |
| 103 | |
| 104 | func (c *PluginRuntimeRegisterCommand) AutocompleteArgs() complete.Predictor { |
| 105 | return nil |
no test coverage detected