Ability to enable unsafe in yaegi through plugin manifest
This commit is contained in:
parent
a092c4f535
commit
8f37c8f0c5
7 changed files with 45 additions and 10 deletions
|
|
@ -11,8 +11,9 @@ const (
|
|||
)
|
||||
|
||||
type Settings struct {
|
||||
Envs []string `description:"Environment variables to forward to the wasm guest." json:"envs,omitempty" toml:"envs,omitempty" yaml:"envs,omitempty"`
|
||||
Mounts []string `description:"Directory to mount to the wasm guest." json:"mounts,omitempty" toml:"mounts,omitempty" yaml:"mounts,omitempty"`
|
||||
Envs []string `description:"Environment variables to forward to the wasm guest." json:"envs,omitempty" toml:"envs,omitempty" yaml:"envs,omitempty"`
|
||||
Mounts []string `description:"Directory to mount to the wasm guest." json:"mounts,omitempty" toml:"mounts,omitempty" yaml:"mounts,omitempty"`
|
||||
UseUnsafe bool `description:"Allow the plugin to use unsafe package." json:"useUnsafe,omitempty" toml:"useUnsafe,omitempty" yaml:"useUnsafe,omitempty"`
|
||||
}
|
||||
|
||||
// Descriptor The static part of a plugin configuration.
|
||||
|
|
@ -46,6 +47,7 @@ type Manifest struct {
|
|||
BasePkg string `yaml:"basePkg"`
|
||||
Compatibility string `yaml:"compatibility"`
|
||||
Summary string `yaml:"summary"`
|
||||
UseUnsafe bool `yaml:"useUnsafe"`
|
||||
TestData map[string]interface{} `yaml:"testData"`
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue