generate

package
v3.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2021 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Kube

func Kube(ctx context.Context, nameOrIDs []string, options *KubeOptions) (*entities.GenerateKubeReport, error)

func Systemd

func Systemd(ctx context.Context, nameOrID string, options *SystemdOptions) (*entities.GenerateSystemdReport, error)

Types

type KubeOptions

type KubeOptions struct {
	// Service - generate YAML for a Kubernetes _service_ object.
	Service *bool
}

KubeOptions are optional options for generating kube YAML files

func (*KubeOptions) Changed

func (o *KubeOptions) Changed(fieldName string) bool

Changed

func (*KubeOptions) GetService

func (o *KubeOptions) GetService() bool

GetService

func (*KubeOptions) ToParams

func (o *KubeOptions) ToParams() (url.Values, error)

ToParams

func (*KubeOptions) WithService

func (o *KubeOptions) WithService(value bool) *KubeOptions

WithService

type SystemdOptions

type SystemdOptions struct {
	// Name - use container/pod name instead of its ID.
	UseName *bool
	// New - create a new container instead of starting a new one.
	New *bool
	// NoHeader - Removes autogenerated by Podman and timestamp if set to true
	NoHeader *bool
	// RestartPolicy - systemd restart policy.
	RestartPolicy *string
	// StopTimeout - time when stopping the container.
	StopTimeout *uint
	// ContainerPrefix - systemd unit name prefix for containers
	ContainerPrefix *string
	// PodPrefix - systemd unit name prefix for pods
	PodPrefix *string
	// Separator - systemd unit name separator between name/id and prefix
	Separator *string
}

SystemdOptions are optional options for generating systemd files

func (*SystemdOptions) Changed

func (o *SystemdOptions) Changed(fieldName string) bool

Changed

func (*SystemdOptions) GetContainerPrefix

func (o *SystemdOptions) GetContainerPrefix() string

GetContainerPrefix

func (*SystemdOptions) GetNew

func (o *SystemdOptions) GetNew() bool

GetNew

func (*SystemdOptions) GetNoHeader added in v3.1.0

func (o *SystemdOptions) GetNoHeader() bool

GetNoHeader

func (*SystemdOptions) GetPodPrefix

func (o *SystemdOptions) GetPodPrefix() string

GetPodPrefix

func (*SystemdOptions) GetRestartPolicy

func (o *SystemdOptions) GetRestartPolicy() string

GetRestartPolicy

func (*SystemdOptions) GetSeparator

func (o *SystemdOptions) GetSeparator() string

GetSeparator

func (*SystemdOptions) GetStopTimeout

func (o *SystemdOptions) GetStopTimeout() uint

GetStopTimeout

func (*SystemdOptions) GetUseName

func (o *SystemdOptions) GetUseName() bool

GetUseName

func (*SystemdOptions) ToParams

func (o *SystemdOptions) ToParams() (url.Values, error)

ToParams

func (*SystemdOptions) WithContainerPrefix

func (o *SystemdOptions) WithContainerPrefix(value string) *SystemdOptions

WithContainerPrefix

func (*SystemdOptions) WithNew

func (o *SystemdOptions) WithNew(value bool) *SystemdOptions

WithNew

func (*SystemdOptions) WithNoHeader added in v3.1.0

func (o *SystemdOptions) WithNoHeader(value bool) *SystemdOptions

WithNoHeader

func (*SystemdOptions) WithPodPrefix

func (o *SystemdOptions) WithPodPrefix(value string) *SystemdOptions

WithPodPrefix

func (*SystemdOptions) WithRestartPolicy

func (o *SystemdOptions) WithRestartPolicy(value string) *SystemdOptions

WithRestartPolicy

func (*SystemdOptions) WithSeparator

func (o *SystemdOptions) WithSeparator(value string) *SystemdOptions

WithSeparator

func (*SystemdOptions) WithStopTimeout

func (o *SystemdOptions) WithStopTimeout(value uint) *SystemdOptions

WithStopTimeout

func (*SystemdOptions) WithUseName

func (o *SystemdOptions) WithUseName(value bool) *SystemdOptions

WithUseName

Jump to

Keyboard shortcuts

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