write go manifest representation
This commit is contained in:
25
api/manifest.go
Normal file
25
api/manifest.go
Normal file
@@ -0,0 +1,25 @@
|
||||
package api
|
||||
|
||||
import "hakurei.app/container/check"
|
||||
|
||||
type Manifest struct {
|
||||
Metadata Metadata `json:"metadata"`
|
||||
Executable Executable `json:"executable"`
|
||||
Capabilities []CapabilityJSON `json:"capabilities"`
|
||||
Permissions []CapabilityJSON `json:"permissions"`
|
||||
}
|
||||
type Metadata struct {
|
||||
ID string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
Description string `json:"description"`
|
||||
Author string `json:"author"`
|
||||
Icon *check.Absolute `json:"icon"`
|
||||
Version int `json:"version"`
|
||||
VersionName string `json:"version_name"`
|
||||
}
|
||||
type Executable struct {
|
||||
BaseImage string `json:"base_image"`
|
||||
Binary *check.Absolute `json:"binary"`
|
||||
Args []string `json:"args"`
|
||||
Env map[string]string `json:"env"`
|
||||
}
|
||||
Reference in New Issue
Block a user