Class ContainerBasicConfig
java.lang.Object
io.github.alersrt.pod4j.openapi.model.ContainerBasicConfig
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2024-11-19T11:19:05.435500352+07:00[Asia/Barnaul]",
comments="Generator version: 7.7.0")
public class ContainerBasicConfig
extends Object
ContainerBasicConfig
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddCommandItem(String commandItem) addContainerCreateCommandItem(String containerCreateCommandItem) addDependencyContainersItem(String dependencyContainersItem) addEntrypointItem(String entrypointItem) addEnvmergeItem(String envmergeItem) addHostusersItem(String hostusersItem) addUnsetenvItem(String unsetenvItem) annotations(Map<String, String> annotations) conmonPidFile(String conmonPidFile) containerCreateCommand(List<String> containerCreateCommand) dependencyContainers(List<String> dependencyContainers) entrypoint(List<String> entrypoint) booleanstatic ContainerBasicConfigCreate an instance of ContainerBasicConfig given an JSON stringAnnotations are key-value options passed into the container runtime that can be used to trigger special behavior.Command is the container's command.ConmonPidFile is a path at which a PID file for Conmon will be placed.ContainerCreateCommand is the command that was used to create this container.DependencyContainers is an array of containers this container depends on.Entrypoint is the container's entrypoint.getEnv()Env is a set of environment variables that will be set in the container.EnvHost indicates that the host environment should be added to container Optional.EnvMerge takes the specified environment variables from image and preprocess them before injecting them into the container.GroupEntry specifies an arbitrary string to append to the container's /etc/group file.Hostname is the container's hostname.HostUsers is a list of host usernames or UIDs to add to the container etc/passwd fileEnvHTTPProxy indicates that the http host proxy environment variables should be added to container Optional.InitContainerType describes if this container is an init container and if so, what type: always or once.Labels are key-value pairs that are used to add metadata to containers.Get logConfigurationPasswd is a container run option that determines if we are validating users/groups before running the containergetName()Name is the name the container will be given.OCIRuntime is the name of the OCI runtime that will be used to create the container.PasswdEntry specifies an arbitrary string to append to the container's /etc/passwd file.Get personalitygetPidns()Get pidnsgetPod()Pod is the ID of the pod the container will join.Remove indicates if the container should be removed once it has been started and exits.RemoveImage indicates that the container should remove the image it was created from after it exits.RestartPolicy is the container's restart policy - an action which will be taken when the container exits.RestartRetries is the number of attempts that will be made to restart the container.Determine how to handle the NOTIFY_SOCKET - do we participate or pass it through \"container\" - let the OCI runtime deal with it, advertise conmon's MAINPID \"conmon-only\" - advertise conmon's MAINPID, send READY when started, don't pass to OCI \"ignore\" - unset NOTIFY_SOCKET Optional.EnvSecrets are secrets that will be set as environment variables Optional.getStdin()Stdin is whether the container will keep its STDIN open.It implements the [os.Signal] interface.StopTimeout is a timeout between the container's stop signal being sent and SIGKILL being sent.Sysctl sets kernel parameters for the containerSystemd is whether the container will be started in systemd mode.Terminal is whether the container will create a PTY.Timeout is a maximum time in seconds the container will run before main process is sent SIGKILL.Timezone is the timezone inside the container.UnsetEnv unsets the specified default environment variables from the image or from built-in or containers.conf Optional.UnsetEnvAll unsetall default environment variables from the image or from built-in or containers.conf UnsetEnvAll unsets all default environment variables from the image or from built-in Optional.getUtsns()Get utsnsgroupEntry(String groupEntry) inthashCode()initContainerType(String initContainerType) logConfiguration(LogConfigLibpod logConfiguration) managePassword(Boolean managePassword) ociRuntime(String ociRuntime) passwdEntry(String passwdEntry) personality(LinuxPersonality personality) putAnnotationsItem(String key, String annotationsItem) putEnvItem(String key, String envItem) putLabelsItem(String key, String labelsItem) putSecretEnvItem(String key, String secretEnvItem) putSysctlItem(String key, String sysctlItem) removeImage(Boolean removeImage) restartPolicy(String restartPolicy) restartTries(Integer restartTries) sdnotifyMode(String sdnotifyMode) voidsetAnnotations(Map<String, String> annotations) voidsetCommand(List<String> command) voidsetConmonPidFile(String conmonPidFile) voidsetContainerCreateCommand(List<String> containerCreateCommand) voidsetDependencyContainers(List<String> dependencyContainers) voidsetEntrypoint(List<String> entrypoint) voidvoidsetEnvHost(Boolean envHost) voidsetEnvmerge(List<String> envmerge) voidsetGroupEntry(String groupEntry) voidsetHostname(String hostname) voidsetHostusers(List<String> hostusers) voidsetHttpproxy(Boolean httpproxy) voidsetInitContainerType(String initContainerType) voidvoidsetLogConfiguration(LogConfigLibpod logConfiguration) voidsetManagePassword(Boolean managePassword) voidvoidsetOciRuntime(String ociRuntime) voidsetPasswdEntry(String passwdEntry) voidsetPersonality(LinuxPersonality personality) voidvoidvoidvoidsetRemoveImage(Boolean removeImage) voidsetRestartPolicy(String restartPolicy) voidsetRestartTries(Integer restartTries) voidsetSdnotifyMode(String sdnotifyMode) voidsetSecretEnv(Map<String, String> secretEnv) voidvoidsetStopSignal(Long stopSignal) voidsetStopTimeout(Integer stopTimeout) voidvoidsetSystemd(String systemd) voidsetTerminal(Boolean terminal) voidsetTimeout(Integer timeout) voidsetTimezone(String timezone) voidsetUnsetenv(List<String> unsetenv) voidsetUnsetenvall(Boolean unsetenvall) voidstopSignal(Long stopSignal) stopTimeout(Integer stopTimeout) toJson()Convert an instance of ContainerBasicConfig to an JSON stringtoString()unsetenvall(Boolean unsetenvall) static voidvalidateJsonElement(com.google.gson.JsonElement jsonElement) Validates the JSON Element and throws an exception if issues found
-
Field Details
-
SERIALIZED_NAME_ANNOTATIONS
- See Also:
-
SERIALIZED_NAME_COMMAND
- See Also:
-
SERIALIZED_NAME_CONMON_PID_FILE
- See Also:
-
SERIALIZED_NAME_CONTAINER_CREATE_COMMAND
- See Also:
-
SERIALIZED_NAME_DEPENDENCY_CONTAINERS
- See Also:
-
SERIALIZED_NAME_ENTRYPOINT
- See Also:
-
SERIALIZED_NAME_ENV
- See Also:
-
SERIALIZED_NAME_ENV_HOST
- See Also:
-
SERIALIZED_NAME_ENVMERGE
- See Also:
-
SERIALIZED_NAME_GROUP_ENTRY
- See Also:
-
SERIALIZED_NAME_HOSTNAME
- See Also:
-
SERIALIZED_NAME_HOSTUSERS
- See Also:
-
SERIALIZED_NAME_HTTPPROXY
- See Also:
-
SERIALIZED_NAME_INIT_CONTAINER_TYPE
- See Also:
-
SERIALIZED_NAME_LABELS
- See Also:
-
SERIALIZED_NAME_LOG_CONFIGURATION
- See Also:
-
SERIALIZED_NAME_MANAGE_PASSWORD
- See Also:
-
SERIALIZED_NAME_NAME
- See Also:
-
SERIALIZED_NAME_OCI_RUNTIME
- See Also:
-
SERIALIZED_NAME_PASSWD_ENTRY
- See Also:
-
SERIALIZED_NAME_PERSONALITY
- See Also:
-
SERIALIZED_NAME_PIDNS
- See Also:
-
SERIALIZED_NAME_POD
- See Also:
-
SERIALIZED_NAME_REMOVE
- See Also:
-
SERIALIZED_NAME_REMOVE_IMAGE
- See Also:
-
SERIALIZED_NAME_RESTART_POLICY
- See Also:
-
SERIALIZED_NAME_RESTART_TRIES
- See Also:
-
SERIALIZED_NAME_SDNOTIFY_MODE
- See Also:
-
SERIALIZED_NAME_SECRET_ENV
- See Also:
-
SERIALIZED_NAME_STDIN
- See Also:
-
SERIALIZED_NAME_STOP_SIGNAL
- See Also:
-
SERIALIZED_NAME_STOP_TIMEOUT
- See Also:
-
SERIALIZED_NAME_SYSCTL
- See Also:
-
SERIALIZED_NAME_SYSTEMD
- See Also:
-
SERIALIZED_NAME_TERMINAL
- See Also:
-
SERIALIZED_NAME_TIMEOUT
- See Also:
-
SERIALIZED_NAME_TIMEZONE
- See Also:
-
SERIALIZED_NAME_UNSETENV
- See Also:
-
SERIALIZED_NAME_UNSETENVALL
- See Also:
-
SERIALIZED_NAME_UTSNS
- See Also:
-
openapiFields
-
openapiRequiredFields
-
-
Constructor Details
-
ContainerBasicConfig
public ContainerBasicConfig()
-
-
Method Details
-
annotations
-
putAnnotationsItem
-
getAnnotations
Annotations are key-value options passed into the container runtime that can be used to trigger special behavior. Optional.- Returns:
- annotations
-
setAnnotations
-
command
-
addCommandItem
-
getCommand
Command is the container's command. If not given and Image is specified, this will be populated by the image's configuration. Optional.- Returns:
- command
-
setCommand
-
conmonPidFile
-
getConmonPidFile
ConmonPidFile is a path at which a PID file for Conmon will be placed. If not given, a default location will be used. Optional.- Returns:
- conmonPidFile
-
setConmonPidFile
-
containerCreateCommand
-
addContainerCreateCommandItem
-
getContainerCreateCommand
ContainerCreateCommand is the command that was used to create this container. This will be shown in the output of Inspect() on the container, and may also be used by some tools that wish to recreate the container (e.g. `podman generate systemd --new`). Optional.- Returns:
- containerCreateCommand
-
setContainerCreateCommand
-
dependencyContainers
-
addDependencyContainersItem
-
getDependencyContainers
DependencyContainers is an array of containers this container depends on. Dependency containers must be started before this container. Dependencies can be specified by name or full/partial ID. Optional.- Returns:
- dependencyContainers
-
setDependencyContainers
-
entrypoint
-
addEntrypointItem
-
getEntrypoint
Entrypoint is the container's entrypoint. If not given and Image is specified, this will be populated by the image's configuration. Optional.- Returns:
- entrypoint
-
setEntrypoint
-
env
-
putEnvItem
-
getEnv
Env is a set of environment variables that will be set in the container. Optional.- Returns:
- env
-
setEnv
-
envHost
-
getEnvHost
EnvHost indicates that the host environment should be added to container Optional.- Returns:
- envHost
-
setEnvHost
-
envmerge
-
addEnvmergeItem
-
getEnvmerge
EnvMerge takes the specified environment variables from image and preprocess them before injecting them into the container. Optional.- Returns:
- envmerge
-
setEnvmerge
-
groupEntry
-
getGroupEntry
GroupEntry specifies an arbitrary string to append to the container's /etc/group file. Optional.- Returns:
- groupEntry
-
setGroupEntry
-
hostname
-
getHostname
Hostname is the container's hostname. If not set, the hostname will not be modified (if UtsNS is not private) or will be set to the container ID (if UtsNS is private). Conflicts with UtsNS if UtsNS is not set to private. Optional.- Returns:
- hostname
-
setHostname
-
hostusers
-
addHostusersItem
-
getHostusers
HostUsers is a list of host usernames or UIDs to add to the container etc/passwd file- Returns:
- hostusers
-
setHostusers
-
httpproxy
-
getHttpproxy
EnvHTTPProxy indicates that the http host proxy environment variables should be added to container Optional.- Returns:
- httpproxy
-
setHttpproxy
-
initContainerType
-
getInitContainerType
InitContainerType describes if this container is an init container and if so, what type: always or once. Optional.- Returns:
- initContainerType
-
setInitContainerType
-
labels
-
putLabelsItem
-
getLabels
Labels are key-value pairs that are used to add metadata to containers. Optional.- Returns:
- labels
-
setLabels
-
logConfiguration
-
getLogConfiguration
Get logConfiguration- Returns:
- logConfiguration
-
setLogConfiguration
-
managePassword
-
getManagePassword
Passwd is a container run option that determines if we are validating users/groups before running the container- Returns:
- managePassword
-
setManagePassword
-
name
-
getName
Name is the name the container will be given. If no name is provided, one will be randomly generated. Optional.- Returns:
- name
-
setName
-
ociRuntime
-
getOciRuntime
OCIRuntime is the name of the OCI runtime that will be used to create the container. If not specified, the default will be used. Optional.- Returns:
- ociRuntime
-
setOciRuntime
-
passwdEntry
-
getPasswdEntry
PasswdEntry specifies an arbitrary string to append to the container's /etc/passwd file. Optional.- Returns:
- passwdEntry
-
setPasswdEntry
-
personality
-
getPersonality
Get personality- Returns:
- personality
-
setPersonality
-
pidns
-
getPidns
Get pidns- Returns:
- pidns
-
setPidns
-
pod
-
getPod
Pod is the ID of the pod the container will join. Optional.- Returns:
- pod
-
setPod
-
remove
-
getRemove
Remove indicates if the container should be removed once it has been started and exits. Optional.- Returns:
- remove
-
setRemove
-
removeImage
-
getRemoveImage
RemoveImage indicates that the container should remove the image it was created from after it exits. Only allowed if Remove is set to true and Image, not Rootfs, is in use. Optional.- Returns:
- removeImage
-
setRemoveImage
-
restartPolicy
-
getRestartPolicy
RestartPolicy is the container's restart policy - an action which will be taken when the container exits. If not given, the default policy, which does nothing, will be used. Optional.- Returns:
- restartPolicy
-
setRestartPolicy
-
restartTries
-
getRestartTries
RestartRetries is the number of attempts that will be made to restart the container. Only available when RestartPolicy is set to \"on-failure\". Optional.- Returns:
- restartTries
-
setRestartTries
-
sdnotifyMode
-
getSdnotifyMode
Determine how to handle the NOTIFY_SOCKET - do we participate or pass it through \"container\" - let the OCI runtime deal with it, advertise conmon's MAINPID \"conmon-only\" - advertise conmon's MAINPID, send READY when started, don't pass to OCI \"ignore\" - unset NOTIFY_SOCKET Optional.- Returns:
- sdnotifyMode
-
setSdnotifyMode
-
secretEnv
-
putSecretEnvItem
-
getSecretEnv
EnvSecrets are secrets that will be set as environment variables Optional.- Returns:
- secretEnv
-
setSecretEnv
-
stdin
-
getStdin
Stdin is whether the container will keep its STDIN open. Optional.- Returns:
- stdin
-
setStdin
-
stopSignal
-
getStopSignal
It implements the [os.Signal] interface.- Returns:
- stopSignal
-
setStopSignal
-
stopTimeout
-
getStopTimeout
StopTimeout is a timeout between the container's stop signal being sent and SIGKILL being sent. If not provided, the default will be used. If 0 is used, stop signal will not be sent, and SIGKILL will be sent instead. Optional.- Returns:
- stopTimeout
-
setStopTimeout
-
sysctl
-
putSysctlItem
-
getSysctl
Sysctl sets kernel parameters for the container- Returns:
- sysctl
-
setSysctl
-
systemd
-
getSystemd
Systemd is whether the container will be started in systemd mode. Valid options are \"true\", \"false\", and \"always\". \"true\" enables this mode only if the binary run in the container is sbin/init or systemd. \"always\" unconditionally enables systemd mode. \"false\" unconditionally disables systemd mode. If enabled, mounts and stop signal will be modified. If set to \"always\" or set to \"true\" and conditionally triggered, conflicts with StopSignal. If not specified, \"false\" will be assumed. Optional.- Returns:
- systemd
-
setSystemd
-
terminal
-
getTerminal
Terminal is whether the container will create a PTY. Optional.- Returns:
- terminal
-
setTerminal
-
timeout
-
getTimeout
Timeout is a maximum time in seconds the container will run before main process is sent SIGKILL. If 0 is used, signal will not be sent. Container can run indefinitely if they do not stop after the default termination signal. Optional.- Returns:
- timeout
-
setTimeout
-
timezone
-
getTimezone
Timezone is the timezone inside the container. Local means it has the same timezone as the host machine Optional.- Returns:
- timezone
-
setTimezone
-
unsetenv
-
addUnsetenvItem
-
getUnsetenv
UnsetEnv unsets the specified default environment variables from the image or from built-in or containers.conf Optional.- Returns:
- unsetenv
-
setUnsetenv
-
unsetenvall
-
getUnsetenvall
UnsetEnvAll unsetall default environment variables from the image or from built-in or containers.conf UnsetEnvAll unsets all default environment variables from the image or from built-in Optional.- Returns:
- unsetenvall
-
setUnsetenvall
-
utsns
-
getUtsns
Get utsns- Returns:
- utsns
-
setUtsns
-
equals
-
hashCode
public int hashCode() -
toString
-
validateJsonElement
Validates the JSON Element and throws an exception if issues found- Parameters:
jsonElement- JSON Element- Throws:
IOException- if the JSON Element is invalid with respect to ContainerBasicConfig
-
fromJson
Create an instance of ContainerBasicConfig given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of ContainerBasicConfig
- Throws:
IOException- if the JSON string is invalid with respect to ContainerBasicConfig
-
toJson
Convert an instance of ContainerBasicConfig to an JSON string- Returns:
- JSON string
-