Documentation ¶
Index ¶
- func Architecture(value, operator string) func(*latest.Constraints)
- func CPUs(cpus string) func(*latest.Resource)
- func Command(s ...string) func(*latest.ServiceConfig)
- func ConfigExternal(c *latest.ConfigObjConfig)
- func ConfigFile(path string) func(*latest.ConfigObjConfig)
- func ConfigGID(gid string) func(*latest.ServiceConfigObjConfig)
- func ConfigMode(mode uint32) func(*latest.ServiceConfigObjConfig)
- func ConfigSource(source string) func(*latest.ServiceConfigObjConfig)
- func ConfigTarget(target string) func(*latest.ServiceConfigObjConfig)
- func ConfigUID(uid string) func(*latest.ServiceConfigObjConfig)
- func ConstraintHostname(value, operator string) func(*latest.Constraints)
- func Constraints(builders ...func(*latest.Constraints)) func(*latest.Placement)
- func Daemonset(owningStack *latest.Stack, name string, builders ...func(*appstypes.DaemonSet)) *appstypes.DaemonSet
- func Deploy(builders ...func(*latest.DeployConfig)) func(*latest.ServiceConfig)
- func Deployment(owningStack *latest.Stack, name string, ...) *appstypes.Deployment
- func Entrypoint(s ...string) func(*latest.ServiceConfig)
- func Healthcheck(builders ...func(*latest.HealthCheckConfig)) func(*latest.ServiceConfig)
- func Hostname(hostname string) func(*latest.ServiceConfig)
- func IPC(mode string) func(*latest.ServiceConfig)
- func Image(reference string) func(*latest.ServiceConfig)
- func Interval(duration time.Duration) func(*latest.HealthCheckConfig)
- func Limits(builders ...func(*latest.Resource)) func(*latest.Resources)
- func Memory(memory int64) func(*latest.Resource)
- func ModeGlobal(d *latest.DeployConfig)
- func Mount(v *latest.ServiceVolumeConfig)
- func OnFailure(r *latest.RestartPolicy)
- func OperatingSystem(value, operator string) func(*latest.Constraints)
- func PID(mode string) func(*latest.ServiceConfig)
- func Parallelism(parallelism uint64) func(*latest.UpdateConfig)
- func Placement(builders ...func(*latest.Placement)) func(*latest.DeployConfig)
- func Privileged(c *latest.ServiceConfig)
- func ProtocolUDP(c *latest.ServicePortConfig)
- func Published(published uint32) func(*latest.ServicePortConfig)
- func PullPolicy(policy string) func(*latest.ServiceConfig)
- func PullSecret(name string) func(*latest.ServiceConfig)
- func ReadOnly(c *latest.ServiceConfig)
- func Replicas(replicas uint64) func(*latest.DeployConfig)
- func Reservations(builders ...func(*latest.Resource)) func(*latest.Resources)
- func Resources(builders ...func(*latest.Resources)) func(*latest.DeployConfig)
- func RestartPolicy(builders ...func(*latest.RestartPolicy)) func(*latest.DeployConfig)
- func Retries(retries uint64) func(*latest.HealthCheckConfig)
- func SecretFile(path string) func(*latest.SecretConfig)
- func SecretSource(source string) func(*latest.ServiceSecretConfig)
- func SecretTarget(target string) func(*latest.ServiceSecretConfig)
- func Service(owningStack *latest.Stack, name string, builders ...func(*coretypes.Service)) *coretypes.Service
- func Source(source string) func(*latest.ServiceVolumeConfig)
- func Stack(name string, builders ...func(*latest.Stack)) *latest.Stack
- func Statefulset(owningStack *latest.Stack, name string, ...) *appstypes.StatefulSet
- func StdinOpen(s *latest.ServiceConfig)
- func StopGracePeriod(duration time.Duration) func(*latest.ServiceConfig)
- func Target(target string) func(*latest.ServiceVolumeConfig)
- func Test(cmd ...string) func(*latest.HealthCheckConfig)
- func Timeout(duration time.Duration) func(*latest.HealthCheckConfig)
- func Tty(s *latest.ServiceConfig)
- func Update(builders ...func(*latest.UpdateConfig)) func(*latest.DeployConfig)
- func User(user int64) func(*latest.ServiceConfig)
- func Volume(v *latest.ServiceVolumeConfig)
- func VolumeReadOnly(v *latest.ServiceVolumeConfig)
- func WithCapAdd(caps ...string) func(*latest.ServiceConfig)
- func WithCapDrop(caps ...string) func(*latest.ServiceConfig)
- func WithConfig(builders ...func(*latest.ServiceConfigObjConfig)) func(*latest.ServiceConfig)
- func WithConfigObjConfig(name string, builders ...func(*latest.ConfigObjConfig)) func(*latest.Stack)
- func WithDeployLabel(key, value string) func(*latest.DeployConfig)
- func WithEnvironment(key string, value *string) func(*latest.ServiceConfig)
- func WithExtraHost(host string) func(*latest.ServiceConfig)
- func WithInternalPort(port int32, protocol corev1.Protocol) func(*latest.ServiceConfig)
- func WithLabel(key, value string) func(*latest.ServiceConfig)
- func WithMatchLabel(key, value, operator string) func(*latest.Constraints)
- func WithNamespace(namespace string) func(*latest.Stack)
- func WithPort(target uint32, builders ...func(*latest.ServicePortConfig)) func(*latest.ServiceConfig)
- func WithSecret(builders ...func(*latest.ServiceSecretConfig)) func(*latest.ServiceConfig)
- func WithSecretConfig(name string, builders ...func(*latest.SecretConfig)) func(*latest.Stack)
- func WithService(name string, builders ...func(*latest.ServiceConfig)) func(*latest.Stack)
- func WithTmpFS(path string) func(*latest.ServiceConfig)
- func WithVolume(builders ...func(*latest.ServiceVolumeConfig)) func(*latest.ServiceConfig)
- func WorkingDir(w string) func(*latest.ServiceConfig)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Architecture ¶
func Architecture(value, operator string) func(*latest.Constraints)
Architecture set the operating system constraint
func Command ¶
func Command(s ...string) func(*latest.ServiceConfig)
Command sets the command of the service
func ConfigExternal ¶
func ConfigExternal(c *latest.ConfigObjConfig)
ConfigExternal specifies that the config is external
func ConfigFile ¶
func ConfigFile(path string) func(*latest.ConfigObjConfig)
ConfigFile specifies the path of a config
func ConfigGID ¶
func ConfigGID(gid string) func(*latest.ServiceConfigObjConfig)
ConfigGID sets the gid of the config
func ConfigMode ¶
func ConfigMode(mode uint32) func(*latest.ServiceConfigObjConfig)
ConfigMode sets the mode of the config
func ConfigSource ¶
func ConfigSource(source string) func(*latest.ServiceConfigObjConfig)
ConfigSource sets the source of the config
func ConfigTarget ¶
func ConfigTarget(target string) func(*latest.ServiceConfigObjConfig)
ConfigTarget sets the target of the config
func ConfigUID ¶
func ConfigUID(uid string) func(*latest.ServiceConfigObjConfig)
ConfigUID sets the uid of the config
func ConstraintHostname ¶
func ConstraintHostname(value, operator string) func(*latest.Constraints)
ConstraintHostname set the operating system constraint
func Constraints ¶
func Constraints(builders ...func(*latest.Constraints)) func(*latest.Placement)
Constraints sets the constraints to the placement
func Daemonset ¶
func Daemonset(owningStack *latest.Stack, name string, builders ...func(*appstypes.DaemonSet)) *appstypes.DaemonSet
Daemonset creates a core Deployment as if owned by a stack
func Deploy ¶
func Deploy(builders ...func(*latest.DeployConfig)) func(*latest.ServiceConfig)
Deploy sets the deploy config of the service
func Deployment ¶
func Deployment(owningStack *latest.Stack, name string, builders ...func(*appstypes.Deployment)) *appstypes.Deployment
Deployment creates a core Deployment as if owned by a stack
func Entrypoint ¶
func Entrypoint(s ...string) func(*latest.ServiceConfig)
Entrypoint sets the entrypoint of the service
func Healthcheck ¶
func Healthcheck(builders ...func(*latest.HealthCheckConfig)) func(*latest.ServiceConfig)
Healthcheck sets the healthcheck config of the service
func Hostname ¶
func Hostname(hostname string) func(*latest.ServiceConfig)
Hostname sets the hostname of the service
func Image ¶
func Image(reference string) func(*latest.ServiceConfig)
Image specfies the image of the service
func Interval ¶
func Interval(duration time.Duration) func(*latest.HealthCheckConfig)
Interval sets the interval duration of the healthcheck
func OnFailure ¶
func OnFailure(r *latest.RestartPolicy)
OnFailure sets the restart policy to on-failure
func OperatingSystem ¶
func OperatingSystem(value, operator string) func(*latest.Constraints)
OperatingSystem set the operating system constraint
func Parallelism ¶
func Parallelism(parallelism uint64) func(*latest.UpdateConfig)
Parallelism sets the parallelism of the update config
func Placement ¶
func Placement(builders ...func(*latest.Placement)) func(*latest.DeployConfig)
Placement sets the placement of the deploy config
func Privileged ¶
func Privileged(c *latest.ServiceConfig)
Privileged sets the service to privileged
func ProtocolUDP ¶
func ProtocolUDP(c *latest.ServicePortConfig)
ProtocolUDP set's the port's protocol
func Published ¶
func Published(published uint32) func(*latest.ServicePortConfig)
Published sets the published port
func PullPolicy ¶ added in v0.4.19
func PullPolicy(policy string) func(*latest.ServiceConfig)
PullPolicy specifies the pull policy used for this service
func PullSecret ¶ added in v0.4.19
func PullSecret(name string) func(*latest.ServiceConfig)
PullSecret specifies the name of the pull secret used for this service
func Replicas ¶
func Replicas(replicas uint64) func(*latest.DeployConfig)
Replicas sets the number of replicas of a deploy config
func Reservations ¶
Reservations sets the reservations of the resources
func Resources ¶
func Resources(builders ...func(*latest.Resources)) func(*latest.DeployConfig)
Resources sets the resources of the deploy config
func RestartPolicy ¶
func RestartPolicy(builders ...func(*latest.RestartPolicy)) func(*latest.DeployConfig)
RestartPolicy sets the restart policy of the deploy config
func Retries ¶
func Retries(retries uint64) func(*latest.HealthCheckConfig)
Retries sets the number of retries of the healthcheck
func SecretFile ¶
func SecretFile(path string) func(*latest.SecretConfig)
SecretFile specifies the path of a secret
func SecretSource ¶
func SecretSource(source string) func(*latest.ServiceSecretConfig)
SecretSource sets the source of the secret
func SecretTarget ¶
func SecretTarget(target string) func(*latest.ServiceSecretConfig)
SecretTarget sets the target of the secret
func Service ¶
func Service(owningStack *latest.Stack, name string, builders ...func(*coretypes.Service)) *coretypes.Service
Service creates a core Service as if owned by a stack
func Source ¶
func Source(source string) func(*latest.ServiceVolumeConfig)
Source sets the volume source
func Statefulset ¶
func Statefulset(owningStack *latest.Stack, name string, builders ...func(*appstypes.StatefulSet)) *appstypes.StatefulSet
Statefulset creates a core Deployment as if owned by a stack
func StdinOpen ¶
func StdinOpen(s *latest.ServiceConfig)
StdinOpen sets the service's stdin opne to true
func StopGracePeriod ¶
func StopGracePeriod(duration time.Duration) func(*latest.ServiceConfig)
StopGracePeriod specifies the stop-grace-period duration of a service
func Target ¶
func Target(target string) func(*latest.ServiceVolumeConfig)
Target sets the volume target
func Test ¶
func Test(cmd ...string) func(*latest.HealthCheckConfig)
Test sets the test commands of the healthcheck
func Timeout ¶
func Timeout(duration time.Duration) func(*latest.HealthCheckConfig)
Timeout sets the timeout duration of the healthcheck
func Update ¶
func Update(builders ...func(*latest.UpdateConfig)) func(*latest.DeployConfig)
Update sets the update config of a deploy config
func VolumeReadOnly ¶
func VolumeReadOnly(v *latest.ServiceVolumeConfig)
VolumeReadOnly sets the volume to readonly
func WithCapAdd ¶
func WithCapAdd(caps ...string) func(*latest.ServiceConfig)
WithCapAdd add a cap add to the service
func WithCapDrop ¶
func WithCapDrop(caps ...string) func(*latest.ServiceConfig)
WithCapDrop adds a cap drop to the service
func WithConfig ¶
func WithConfig(builders ...func(*latest.ServiceConfigObjConfig)) func(*latest.ServiceConfig)
WithConfig adds a config to the service
func WithConfigObjConfig ¶
func WithConfigObjConfig(name string, builders ...func(*latest.ConfigObjConfig)) func(*latest.Stack)
WithConfigObjConfig add a ConfigConfig to to stack
func WithDeployLabel ¶
func WithDeployLabel(key, value string) func(*latest.DeployConfig)
WithDeployLabel adds a label to the deploy config
func WithEnvironment ¶
func WithEnvironment(key string, value *string) func(*latest.ServiceConfig)
WithEnvironment adds an environment variable to the service
func WithExtraHost ¶
func WithExtraHost(host string) func(*latest.ServiceConfig)
WithExtraHost adds an extra host to the service
func WithInternalPort ¶ added in v0.4.21
func WithInternalPort(port int32, protocol corev1.Protocol) func(*latest.ServiceConfig)
WithInternalPort adds an internal port declaration
func WithLabel ¶
func WithLabel(key, value string) func(*latest.ServiceConfig)
WithLabel adds a label to a service
func WithMatchLabel ¶
func WithMatchLabel(key, value, operator string) func(*latest.Constraints)
WithMatchLabel adds the labels constraint to the constraint
func WithNamespace ¶
WithNamespace set the namespace of the stack
func WithPort ¶
func WithPort(target uint32, builders ...func(*latest.ServicePortConfig)) func(*latest.ServiceConfig)
WithPort adds a port config to the service
func WithSecret ¶
func WithSecret(builders ...func(*latest.ServiceSecretConfig)) func(*latest.ServiceConfig)
WithSecret adds a secret to the service
func WithSecretConfig ¶
func WithSecretConfig(name string, builders ...func(*latest.SecretConfig)) func(*latest.Stack)
WithSecretConfig add a SecretConfig to to stack
func WithService ¶
func WithService(name string, builders ...func(*latest.ServiceConfig)) func(*latest.Stack)
WithService adds a ServiceConifg to the stack
func WithTmpFS ¶
func WithTmpFS(path string) func(*latest.ServiceConfig)
WithTmpFS adds a path to the tmpfs of a service
func WithVolume ¶
func WithVolume(builders ...func(*latest.ServiceVolumeConfig)) func(*latest.ServiceConfig)
WithVolume adds a volume to the service
func WorkingDir ¶
func WorkingDir(w string) func(*latest.ServiceConfig)
WorkingDir sets the service's working folder
Types ¶
This section is empty.