types

package
v1.0.39 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeEnv      = "env"
	TypeWorkload = "workload"
)

Variables

View Source
var (
	MonoidEnvVolume = TypeMonoidEnvVolume{
		Seed: stringMonoid,
	}

	MonoidWorkloadVolume = TypeMonoidWorkloadVolume{
		Seed:       stringMonoid,
		Filesystem: stringRefMonoid,
		Mount:      stringRefMonoid,
	}

	MonoidWorkloadVolumes = TypeMonoidWorkloadVolumes{
		Volume: M.MakeMonoid(func(left, right WorkloadVolume) WorkloadVolume {
			return WorkloadVolume{
				Seed:       MonoidWorkloadVolume.Seed.Concat(left.Seed, right.Seed),
				Filesystem: MonoidWorkloadVolume.Filesystem.Concat(left.Filesystem, right.Filesystem),
				Mount:      MonoidWorkloadVolume.Mount.Concat(left.Mount, right.Mount),
			}
		}, WorkloadVolume{
			Seed:       MonoidWorkloadVolume.Seed.Empty(),
			Filesystem: MonoidWorkloadVolume.Filesystem.Empty(),
			Mount:      MonoidWorkloadVolume.Mount.Empty(),
		}),
	}

	MonoidEnvVolumes = TypeMonoidEnvVolumes{
		Volume: M.MakeMonoid(func(left, right EnvVolume) EnvVolume {
			return EnvVolume{
				Seed: MonoidEnvVolume.Seed.Concat(left.Seed, right.Seed),
			}
		}, EnvVolume{
			Seed: MonoidEnvVolume.Seed.Empty(),
		}),
	}

	// MonoidWorkload contains the monoids for the fields in the workload
	MonoidWorkload = TypeMonoidWorkload{
		Type:    M.MakeMonoid(F.Second[string, string], TypeWorkload),
		Volumes: R.UnionMonoid[string, WorkloadVolume](MonoidWorkloadVolumes.Volume),
	}

	// MonoidEnv contains the monoids for the fields in the env type
	MonoidEnv = TypeMonoidEnv{
		Type:    M.MakeMonoid(F.Second[string, string], TypeEnv),
		Volumes: R.UnionMonoid[string, EnvVolume](MonoidEnvVolumes.Volume),
	}

	MonoidContract = TypeMonoidContract{
		Workload: M.MakeMonoid(func(left, right *Workload) *Workload {
			if left == nil {
				return right
			}
			if right == nil {
				return left
			}
			return &Workload{
				Type:    MonoidWorkload.Type.Concat(left.Type, right.Type),
				Volumes: MonoidWorkload.Volumes.Concat(left.Volumes, right.Volumes),
			}
		}, &Workload{
			Type:    MonoidWorkload.Type.Empty(),
			Volumes: MonoidWorkload.Volumes.Empty(),
		}),
		Env: M.MakeMonoid(func(left, right *Env) *Env {
			if left == nil {
				return right
			}
			if right == nil {
				return left
			}
			return &Env{
				Type:    MonoidEnv.Type.Concat(left.Type, right.Type),
				Volumes: MonoidEnv.Volumes.Concat(left.Volumes, right.Volumes),
			}
		}, &Env{
			Type:    MonoidEnv.Type.Empty(),
			Volumes: MonoidEnv.Volumes.Empty(),
		}),
		AttestationPublicKey: stringRefMonoid,
		EnvWorkloadSignature: stringRefMonoid,
	}

	// ContractMonoid is a monoid that allows to merge contracts
	ContractMonoid = M.MakeMonoid(func(left, right *Contract) *Contract {
		if left == nil {
			return right
		}
		if right == nil {
			return left
		}
		return &Contract{
			Workload:             MonoidContract.Workload.Concat(left.Workload, right.Workload),
			Env:                  MonoidContract.Env.Concat(left.Env, right.Env),
			AttestationPublicKey: MonoidContract.AttestationPublicKey.Concat(left.AttestationPublicKey, right.AttestationPublicKey),
			EnvWorkloadSignature: MonoidContract.EnvWorkloadSignature.Concat(left.EnvWorkloadSignature, right.EnvWorkloadSignature),
		}
	}, &Contract{
		Workload:             MonoidContract.Workload.Empty(),
		Env:                  MonoidContract.Env.Empty(),
		AttestationPublicKey: MonoidContract.AttestationPublicKey.Empty(),
		EnvWorkloadSignature: MonoidContract.EnvWorkloadSignature.Empty(),
	})
)
View Source
var (

	// OpticEnvVolume contains the optical elements to access fields in an env volume
	OpticEnvVolume = TypeOpticEnvVolume{
		Seed: L.MakeLensRef((*EnvVolume).GetSeed, (*EnvVolume).SetSeed),
	}

	// OpticWorkloadVolume contains the optical elements to access fields in a workload volume
	OpticWorkloadVolume = TypeOpticWorkloadVolume{
		Seed:       L.MakeLensRef((*WorkloadVolume).GetSeed, (*WorkloadVolume).SetSeed),
		Filesystem: fromNillableWorkloadVolumeString(L.MakeLensRef((*WorkloadVolume).GetFilesystem, (*WorkloadVolume).SetFilesystem)),
		Mount:      fromNillableWorkloadVolumeString(L.MakeLensRef((*WorkloadVolume).GetMount, (*WorkloadVolume).SetMount)),
	}

	// OpticLogDNA contains the optical elements to access fields in the logDNA section
	OpticLogDNA = TypeOpticLogDNA{
		IngestionKey: L.MakeLensRef((*LogDNA).GetIngestionKey, (*LogDNA).SetIngestionKey),
		Hostname:     L.MakeLensRef((*LogDNA).GetHostname, (*LogDNA).SetHostname),
		Port:         LI.Compose[*LogDNA](intIso)(L.MakeLensRef((*LogDNA).GetPort, (*LogDNA).SetPort)),
		Tags:         LI.Compose[*LogDNA](fromNillableSlice[[]string]())(L.MakeLensRef((*LogDNA).GetTags, (*LogDNA).SetTags)),
	}

	// OpticSysLog contains the optical elements to access fields in the syslog section
	OpticSysLog = TypeOpticSysLog{
		Server:   L.MakeLensRef((*SysLog).GetServer, (*SysLog).SetServer),
		Hostname: L.MakeLensRef((*SysLog).GetHostname, (*SysLog).SetHostname),
		Port:     fromNillableSysLogInt(L.MakeLensRef((*SysLog).GetPort, (*SysLog).SetPort)),
		Cert:     fromNillableSysLogString(L.MakeLensRef((*SysLog).GetCert, (*SysLog).SetCert)),
		Key:      fromNillableSysLogString(L.MakeLensRef((*SysLog).GetKey, (*SysLog).SetKey)),
	}

	// OpticRedHatSigning contains the optical elements to access fields in the red had signing section
	OpticRedHatSigning = TypeOpticRedHatSigning{
		PublicKey: L.MakeLensRef((*RedHatSigning).GetPublicKey, (*RedHatSigning).SetPublicKey),
	}

	// OpticDockerContentTrust contains the optical elements to access fields in the docker content trust section
	OpticDockerContentTrust = TypeOpticDockerContentTrust{
		Notary:    L.MakeLensRef((*DockerContentTrust).GetNotary, (*DockerContentTrust).SetNotary),
		PublicKey: L.MakeLensRef((*DockerContentTrust).GetPublicKey, (*DockerContentTrust).SetPublicKey),
	}

	// OpticImages contains the optical elements to access fields in the images section
	OpticImages = TypesOpticImages{
		DockerContentTrust: LI.Compose[*Images](fromNillableMap[DockerContentTrusts]())(L.MakeLensRef((*Images).GetDockerContentTrust, (*Images).SetDockerContentTrust)),
		RedHatSigning:      LI.Compose[*Images](fromNillableMap[RedHatSignings]())(L.MakeLensRef((*Images).GetRedHatSigning, (*Images).SetRedHatSigning)),
	}

	// OpticWorkload contains the optical elements to access fields in the workload section
	OpticWorkload = TypeOpticWorkload{
		Type:                   L.MakeLensRef((*Workload).GetType, (*Workload).SetType),
		Volumes:                LI.Compose[*Workload](fromNillableMap[WorkloadVolumes]())(L.MakeLensRef((*Workload).GetVolumes, (*Workload).SetVolumes)),
		Auths:                  LI.Compose[*Workload](fromNillableMap[Auths]())(L.MakeLensRef((*Workload).GetAuths, (*Workload).SetAuths)),
		Images:                 L.FromNillable(L.MakeLensRef((*Workload).GetImages, (*Workload).SetImages)),
		Env:                    LI.Compose[*Workload](fromNillableMap[ENV.Env]())(L.MakeLensRef((*Workload).GetEnv, (*Workload).SetEnv)),
		Compose:                L.FromNillable(L.MakeLensRef((*Workload).GetCompose, (*Workload).SetCompose)),
		Play:                   L.FromNillable(L.MakeLensRef((*Workload).GetPlay, (*Workload).SetPlay)),
		ConfidentialContainers: L.MakeLensRef((*Workload).GetConfidentialContainers, (*Workload).SetConfidentialContainers),
	}

	// OpticEnv contains the optical elements to access fields in the env section
	OpticEnv = TypeOpticEnv{
		Type:    L.MakeLensRef((*Env).GetType, (*Env).SetType),
		Volumes: LI.Compose[*Env](fromNillableMap[EnvVolumes]())(L.MakeLensRef((*Env).GetVolumes, (*Env).SetVolumes)),
		Env:     LI.Compose[*Env](fromNillableMap[ENV.Env]())(L.MakeLensRef((*Env).GetEnv, (*Env).SetEnv)),
	}

	// OpticContract contains the optical elements to access fields in the contract
	OpticContract = TypeOpticContract{
		Workload:             L.FromNillable(L.MakeLensRef((*Contract).GetWorkload, (*Contract).SetWorkload)),
		Env:                  L.FromNillable(L.MakeLensRef((*Contract).GetEnv, (*Contract).SetEnv)),
		AttestationPublicKey: fromNillableContractString(L.MakeLensRef((*Contract).GetAttestationPublicKey, (*Contract).SetAttestationPublicKey)),
		EnvWorkloadSignature: fromNillableContractString(L.MakeLensRef((*Contract).GetEnvWorkloadSignature, (*Contract).SetEnvWorkloadSignature)),
	}
)
View Source
var (
	EmptyImages         = Images{}
	EmptyRedHatSignings = R.Empty[string, *RedHatSigning]()
	EmptyRedHatSigning  = RedHatSigning{}

	FilesystemExt4  = "ext4"
	FilesystemXFS   = "xfs"
	FilesystemBtrFS = "btrfs"
)

Functions

func FromPredicate

func FromPredicate[S, A any](schema *jsonschema.Schema) func(sa L.Lens[S, O.Option[any]]) L.Lens[S, O.Option[A]]

FromPredicate creates an option to focus on a property type any. The data will be validated against a json schema and converted into the desired type

func ValidateAndDecode

func ValidateAndDecode[T any](schema *jsonschema.Schema) func(data any) E.Either[error, T]

ValidateAndDecode validates a data structure against a schema and then decodes it

func ValidateContract

func ValidateContract(raw AnyMap) E.Either[error, *Contract]

ValidateContract validates the given contract against the contract schema

Types

type AnyMap

type AnyMap = map[string]any

type Auths

type Auths = map[string]Credential

type Compose

type Compose struct {
	Archive string `json:"archive" yaml:"archive"`
}

func (*Compose) GetArchive

func (compose *Compose) GetArchive() string

func (*Compose) SetArchive

func (compose *Compose) SetArchive(Archive string) *Compose

type Contract

type Contract struct {
	Workload             *Workload `json:"workload,omitempty" yaml:"workload,omitempty"`
	Env                  *Env      `json:"env,omitempty" yaml:"env,omitempty"`
	AttestationPublicKey *string   `json:"attestationPublicKey,omitempty" yaml:"attestationPublicKey,omitempty"`
	EnvWorkloadSignature *string   `json:"envWorkloadSignature,omitempty" yaml:"envWorkloadSignature,omitempty"`
}

func (*Contract) GetAttestationPublicKey

func (contract *Contract) GetAttestationPublicKey() *string

func (*Contract) GetEnv

func (contract *Contract) GetEnv() *Env

func (*Contract) GetEnvWorkloadSignature

func (contract *Contract) GetEnvWorkloadSignature() *string

func (*Contract) GetWorkload

func (contract *Contract) GetWorkload() *Workload

func (*Contract) SetAttestationPublicKey

func (contract *Contract) SetAttestationPublicKey(AttestationPublicKey *string) *Contract

func (*Contract) SetEnv

func (contract *Contract) SetEnv(Env *Env) *Contract

func (*Contract) SetEnvWorkloadSignature

func (contract *Contract) SetEnvWorkloadSignature(EnvWorkloadSignature *string) *Contract

func (*Contract) SetWorkload

func (contract *Contract) SetWorkload(Workload *Workload) *Contract

type Credential

type Credential struct {
	Username string `json:"username" yaml:"username"`
	Password string `json:"password" yaml:"password"`
}

func (*Credential) GetPassword

func (credential *Credential) GetPassword() string

func (*Credential) GetUsername

func (credential *Credential) GetUsername() string

func (*Credential) SetPassword

func (credential *Credential) SetPassword(Password string) *Credential

func (*Credential) SetUsername

func (credential *Credential) SetUsername(Username string) *Credential

type DockerContentTrust

type DockerContentTrust struct {
	Notary    string `json:"notary" yaml:"notary"`
	PublicKey string `json:"publicKey" yaml:"publicKey"`
}

func (*DockerContentTrust) GetNotary

func (dockercontenttrust *DockerContentTrust) GetNotary() string

func (*DockerContentTrust) GetPublicKey

func (dockercontenttrust *DockerContentTrust) GetPublicKey() string

func (*DockerContentTrust) SetNotary

func (dockercontenttrust *DockerContentTrust) SetNotary(Notary string) *DockerContentTrust

func (*DockerContentTrust) SetPublicKey

func (dockercontenttrust *DockerContentTrust) SetPublicKey(PublicKey string) *DockerContentTrust

type DockerContentTrusts

type DockerContentTrusts = map[string]*DockerContentTrust

type Env

type Env struct {
	Type                   string     `json:"type" yaml:"type"`
	Logging                *Logging   `json:"logging,omitempty" yaml:"logging,omitempty"`
	Volumes                EnvVolumes `json:"volumes,omitempty" yaml:"volumes,omitempty"`
	Env                    ENV.Env    `json:"env,omitempty" yaml:"env,omitempty"`
	SigningKey             *string    `json:"signingKey,omitempty" yaml:"signingKey,omitempty"`
	ConfidentialContainers any        `json:"confidential-containers,omitempty" yaml:"confidential-containers,omitempty"`
}

func (*Env) GetConfidentialContainers

func (env *Env) GetConfidentialContainers() any

func (*Env) GetEnv

func (env *Env) GetEnv() ENV.Env

func (*Env) GetLogging

func (env *Env) GetLogging() *Logging

func (*Env) GetSigningKey

func (env *Env) GetSigningKey() *string

func (*Env) GetType

func (env *Env) GetType() string

func (*Env) GetVolumes

func (env *Env) GetVolumes() EnvVolumes

func (*Env) SetConfidentialContainers

func (env *Env) SetConfidentialContainers(ConfidentialContainers any) *Env

func (*Env) SetEnv

func (env *Env) SetEnv(Env ENV.Env) *Env

func (*Env) SetLogging

func (env *Env) SetLogging(Logging *Logging) *Env

func (*Env) SetSigningKey

func (env *Env) SetSigningKey(SigningKey *string) *Env

func (*Env) SetType

func (env *Env) SetType(Type string) *Env

func (*Env) SetVolumes

func (env *Env) SetVolumes(Volumes EnvVolumes) *Env

type EnvVolume

type EnvVolume struct {
	Seed string `json:"seed" yaml:"seed"`
}

func (*EnvVolume) GetSeed

func (envvolume *EnvVolume) GetSeed() string

func (*EnvVolume) SetSeed

func (envvolume *EnvVolume) SetSeed(Seed string) *EnvVolume

type EnvVolumes

type EnvVolumes = map[string]EnvVolume

type Images

type Images struct {
	DockerContentTrust DockerContentTrusts `json:"dct,omitempty" yaml:"dct,omitempty"`
	RedHatSigning      RedHatSignings      `json:"rhs,omitempty" yaml:"rhs,omitempty"`
}

func (*Images) GetDockerContentTrust

func (images *Images) GetDockerContentTrust() DockerContentTrusts

func (*Images) GetRedHatSigning

func (images *Images) GetRedHatSigning() RedHatSignings

func (*Images) SetDockerContentTrust

func (images *Images) SetDockerContentTrust(DockerContentTrust DockerContentTrusts) *Images

func (*Images) SetRedHatSigning

func (images *Images) SetRedHatSigning(RedHatSigning RedHatSignings) *Images

type LogDNA

type LogDNA struct {
	IngestionKey string   `json:"ingestionKey" yaml:"ingestionKey"`
	Hostname     string   `json:"hostname" yaml:"hostname"`
	Port         *int     `json:"port,omitempty" yaml:"port,omitempty"`
	Tags         []string `json:"tags,omitempty" yaml:"tags,omitempty"`
}

func (*LogDNA) GetHostname

func (logdna *LogDNA) GetHostname() string

func (*LogDNA) GetIngestionKey

func (logdna *LogDNA) GetIngestionKey() string

func (*LogDNA) GetPort

func (logdna *LogDNA) GetPort() *int

func (*LogDNA) GetTags

func (logdna *LogDNA) GetTags() []string

func (*LogDNA) SetHostname

func (logdna *LogDNA) SetHostname(Hostname string) *LogDNA

func (*LogDNA) SetIngestionKey

func (logdna *LogDNA) SetIngestionKey(IngestionKey string) *LogDNA

func (*LogDNA) SetPort

func (logdna *LogDNA) SetPort(Port *int) *LogDNA

func (*LogDNA) SetTags

func (logdna *LogDNA) SetTags(Tags []string) *LogDNA

type Logging

type Logging struct {
	LogDNA *LogDNA `json:"logDNA,omitempty" yaml:"logDNA,omitempty"`
	SysLog *SysLog `json:"syslog,omitempty" yaml:"syslog,omitempty"`
}

func (*Logging) GetLogDNA

func (logging *Logging) GetLogDNA() *LogDNA

func (*Logging) GetSysLog

func (logging *Logging) GetSysLog() *SysLog

func (*Logging) SetLogDNA

func (logging *Logging) SetLogDNA(LogDNA *LogDNA) *Logging

func (*Logging) SetSysLog

func (logging *Logging) SetSysLog(SysLog *SysLog) *Logging

type Play

type Play struct {
	Archive string `json:"archive" yaml:"archive"`
}

func (*Play) GetArchive

func (play *Play) GetArchive() string

func (*Play) SetArchive

func (play *Play) SetArchive(Archive string) *Play

type RedHatSigning

type RedHatSigning struct {
	PublicKey string `json:"publicKey" yaml:"publicKey"`
}

func (*RedHatSigning) GetPublicKey

func (redhatsigning *RedHatSigning) GetPublicKey() string

func (*RedHatSigning) SetPublicKey

func (redhatsigning *RedHatSigning) SetPublicKey(PublicKey string) *RedHatSigning

type RedHatSignings

type RedHatSignings = map[string]*RedHatSigning

type StringMap

type StringMap = map[string]string

type SysLog

type SysLog struct {
	Server   string  `json:"server" yaml:"server"`
	Hostname string  `json:"hostname" yaml:"hostname"`
	Port     *int    `json:"port,omitempty" yaml:"port,omitempty"`
	Cert     *string `json:"cert,omitempty" yaml:"cert,omitempty"`
	Key      *string `json:"key,omitempty" yaml:"key,omitempty"`
}

func (*SysLog) GetCert

func (syslog *SysLog) GetCert() *string

func (*SysLog) GetHostname

func (syslog *SysLog) GetHostname() string

func (*SysLog) GetKey

func (syslog *SysLog) GetKey() *string

func (*SysLog) GetPort

func (syslog *SysLog) GetPort() *int

func (*SysLog) GetServer

func (syslog *SysLog) GetServer() string

func (*SysLog) SetCert

func (syslog *SysLog) SetCert(Cert *string) *SysLog

func (*SysLog) SetHostname

func (syslog *SysLog) SetHostname(Hostname string) *SysLog

func (*SysLog) SetKey

func (syslog *SysLog) SetKey(Key *string) *SysLog

func (*SysLog) SetPort

func (syslog *SysLog) SetPort(Port *int) *SysLog

func (*SysLog) SetServer

func (syslog *SysLog) SetServer(Server string) *SysLog

type TypeMonoidContract

type TypeMonoidContract struct {
	Workload             M.Monoid[*Workload]
	Env                  M.Monoid[*Env]
	AttestationPublicKey M.Monoid[*string]
	EnvWorkloadSignature M.Monoid[*string]
}

type TypeMonoidEnv

type TypeMonoidEnv struct {
	Type    M.Monoid[string]
	Volumes M.Monoid[EnvVolumes]
}

type TypeMonoidEnvVolume

type TypeMonoidEnvVolume struct {
	Seed M.Monoid[string]
}

type TypeMonoidEnvVolumes

type TypeMonoidEnvVolumes struct {
	Volume M.Monoid[EnvVolume]
}

type TypeMonoidWorkload

type TypeMonoidWorkload struct {
	Type    M.Monoid[string]
	Volumes M.Monoid[WorkloadVolumes]
}

type TypeMonoidWorkloadVolume

type TypeMonoidWorkloadVolume struct {
	Seed       M.Monoid[string]
	Filesystem M.Monoid[*string]
	Mount      M.Monoid[*string]
}

type TypeMonoidWorkloadVolumes

type TypeMonoidWorkloadVolumes struct {
	Volume M.Monoid[WorkloadVolume]
}

type TypeOpticContract

type TypeOpticContract struct {
	Workload             L.Lens[*Contract, O.Option[*Workload]]
	Env                  L.Lens[*Contract, O.Option[*Env]]
	AttestationPublicKey L.Lens[*Contract, O.Option[string]]
	EnvWorkloadSignature L.Lens[*Contract, O.Option[string]]
}

type TypeOpticDockerContentTrust

type TypeOpticDockerContentTrust struct {
	Notary    L.Lens[*DockerContentTrust, string]
	PublicKey L.Lens[*DockerContentTrust, string]
}

type TypeOpticEnv

type TypeOpticEnv struct {
	Type    L.Lens[*Env, string]
	Volumes L.Lens[*Env, O.Option[EnvVolumes]]
	Env     L.Lens[*Env, O.Option[ENV.Env]]
}

type TypeOpticEnvVolume

type TypeOpticEnvVolume struct {
	Seed L.Lens[*EnvVolume, string]
}

type TypeOpticLogDNA

type TypeOpticLogDNA struct {
	IngestionKey L.Lens[*LogDNA, string]
	Hostname     L.Lens[*LogDNA, string]
	Port         L.Lens[*LogDNA, O.Option[int]]
	Tags         L.Lens[*LogDNA, O.Option[[]string]]
}

type TypeOpticRedHatSigning

type TypeOpticRedHatSigning struct {
	PublicKey L.Lens[*RedHatSigning, string]
}

type TypeOpticSysLog

type TypeOpticSysLog struct {
	Server   L.Lens[*SysLog, string]
	Hostname L.Lens[*SysLog, string]
	Port     L.Lens[*SysLog, O.Option[int]]
	Cert     L.Lens[*SysLog, O.Option[string]]
	Key      L.Lens[*SysLog, O.Option[string]]
}

type TypeOpticWorkload

type TypeOpticWorkload struct {
	Type                   L.Lens[*Workload, string]
	Volumes                L.Lens[*Workload, O.Option[WorkloadVolumes]]
	Auths                  L.Lens[*Workload, O.Option[Auths]]
	Images                 L.Lens[*Workload, O.Option[*Images]]
	Env                    L.Lens[*Workload, O.Option[ENV.Env]]
	Compose                L.Lens[*Workload, O.Option[*Compose]]
	Play                   L.Lens[*Workload, O.Option[*Play]]
	ConfidentialContainers L.Lens[*Workload, any]
}

type TypeOpticWorkloadVolume

type TypeOpticWorkloadVolume struct {
	Seed       L.Lens[*WorkloadVolume, string]
	Filesystem L.Lens[*WorkloadVolume, O.Option[string]]
	Mount      L.Lens[*WorkloadVolume, O.Option[string]]
}

type TypesOpticImages

type TypesOpticImages struct {
	DockerContentTrust L.Lens[*Images, O.Option[DockerContentTrusts]]
	RedHatSigning      L.Lens[*Images, O.Option[RedHatSignings]]
}

type Workload

type Workload struct {
	Type                   string          `json:"type" yaml:"type"`
	Volumes                WorkloadVolumes `json:"volumes,omitempty" yaml:"volumes,omitempty"`
	Auths                  Auths           `json:"auths,omitempty" yaml:"auths,omitempty"`
	Images                 *Images         `json:"images,omitempty" yaml:"images,omitempty"`
	Env                    ENV.Env         `json:"env,omitempty" yaml:"env,omitempty"`
	Compose                *Compose        `json:"compose,omitempty" yaml:"compose,omitempty"`
	Play                   *Play           `json:"play,omitempty" yaml:"play,omitempty"`
	ConfidentialContainers any             `json:"confidential-containers,omitempty" yaml:"confidential-containers,omitempty"`
}

func (*Workload) GetAuths

func (workload *Workload) GetAuths() Auths

func (*Workload) GetCompose

func (workload *Workload) GetCompose() *Compose

func (*Workload) GetConfidentialContainers

func (workload *Workload) GetConfidentialContainers() any

func (*Workload) GetEnv

func (workload *Workload) GetEnv() ENV.Env

func (*Workload) GetImages

func (workload *Workload) GetImages() *Images

func (*Workload) GetPlay

func (workload *Workload) GetPlay() *Play

func (*Workload) GetType

func (workload *Workload) GetType() string

func (*Workload) GetVolumes

func (workload *Workload) GetVolumes() WorkloadVolumes

func (*Workload) SetAuths

func (workload *Workload) SetAuths(Auths Auths) *Workload

func (*Workload) SetCompose

func (workload *Workload) SetCompose(Compose *Compose) *Workload

func (*Workload) SetConfidentialContainers

func (workload *Workload) SetConfidentialContainers(ConfidentialContainers any) *Workload

func (*Workload) SetEnv

func (workload *Workload) SetEnv(Env ENV.Env) *Workload

func (*Workload) SetImages

func (workload *Workload) SetImages(Images *Images) *Workload

func (*Workload) SetPlay

func (workload *Workload) SetPlay(Play *Play) *Workload

func (*Workload) SetType

func (workload *Workload) SetType(Type string) *Workload

func (*Workload) SetVolumes

func (workload *Workload) SetVolumes(Volumes WorkloadVolumes) *Workload

type WorkloadVolume

type WorkloadVolume struct {
	Seed       string  `json:"seed" yaml:"seed"`
	Filesystem *string `json:"filesystem,omitempty" yaml:"filesystem,omitempty"`
	Mount      *string `json:"mount,omitempty" yaml:"mount,omitempty"`
}

func (*WorkloadVolume) GetFilesystem

func (workloadvolume *WorkloadVolume) GetFilesystem() *string

func (*WorkloadVolume) GetMount

func (workloadvolume *WorkloadVolume) GetMount() *string

func (*WorkloadVolume) GetSeed

func (workloadvolume *WorkloadVolume) GetSeed() string

func (*WorkloadVolume) SetFilesystem

func (workloadvolume *WorkloadVolume) SetFilesystem(Filesystem *string) *WorkloadVolume

func (*WorkloadVolume) SetMount

func (workloadvolume *WorkloadVolume) SetMount(Mount *string) *WorkloadVolume

func (*WorkloadVolume) SetSeed

func (workloadvolume *WorkloadVolume) SetSeed(Seed string) *WorkloadVolume

type WorkloadVolumes

type WorkloadVolumes = map[string]WorkloadVolume

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL