3 fYf@s8dZddlmZddlmZddlZGdddeZdS)z Kubernetes No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) OpenAPI spec version: v1.7.4 Generated by: https://github.com/swagger-api/swagger-codegen.git )pformat) iteritemsNc@sJeZdZdZdKddZeddZejddZedd Zejd d Zed d Z e jd d Z eddZ e jddZ eddZ e jddZ eddZ e jddZ eddZ e jddZ eddZejddZeddZejddZed d!Zejd"d!Zed#d$Zejd%d$Zed&d'Zejd(d'Zed)d*Zejd+d*Zed,d-Zejd.d-Zed/d0Zejd1d0Zed2d3Zejd4d3Zed5d6Zejd7d6Zed8d9Zejd:d9Zed;d<Zejd=d<Zed>d?Zejd@d?ZdAdBZdCdDZdEdFZdGdHZdIdJZdS)L V1Containerzw NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. NcCsddddddddddddd d d ddd d dd |_d ddddddddddddddddddd d |_||_||_||_||_||_||_||_||_ | |_ | |_ | |_ | |_ | |_||_||_||_||_||_||_||_d!S)"aA V1Container - a model defined in Swagger :param dict swaggerTypes: The key is attribute name and the value is attribute type. :param dict attributeMap: The key is attribute name and the value is json key in definition. z list[str]zlist[V1EnvVar]zlist[V1EnvFromSource]str V1LifecycleV1Probezlist[V1ContainerPort]V1ResourceRequirementsV1SecurityContextboolzlist[V1VolumeMount])argscommandenvenv_fromimageimage_pull_policy lifecycleliveness_probenameportsreadiness_probe resourcessecurity_contextstdin stdin_oncetermination_message_pathtermination_message_policytty volume_mounts working_dirr r r ZenvFromrZimagePullPolicyrZ livenessProberrZreadinessProberZsecurityContextrZ stdinOnceZterminationMessagePathZterminationMessagePolicyrZ volumeMountsZ workingDirN) swagger_types attribute_map_args_command_env _env_from_image_image_pull_policy _lifecycle_liveness_probe_name_ports_readiness_probe _resources_security_context_stdin _stdin_once_termination_message_path_termination_message_policy_tty_volume_mounts _working_dir)selfr r r rrrrrrrrrrrrrrrrrr6V/Users/olari/OneDrive/sandbox/awsBlog2/lambda/kubernetes/client/models/v1_container.py__init__sx   zV1Container.__init__cCs|jS)a Gets the args of this V1Container. Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell :return: The args of this V1Container. :rtype: list[str] )r!)r5r6r6r7r ds zV1Container.argscCs ||_dS)a Sets the args of this V1Container. Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell :param args: The args of this V1Container. :type: list[str] N)r!)r5r r6r6r7r os cCs|jS)a Gets the command of this V1Container. Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell :return: The command of this V1Container. :rtype: list[str] )r")r5r6r6r7r {s zV1Container.commandcCs ||_dS)a Sets the command of this V1Container. Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell :param command: The command of this V1Container. :type: list[str] N)r")r5r r6r6r7r s cCs|jS)z Gets the env of this V1Container. List of environment variables to set in the container. Cannot be updated. :return: The env of this V1Container. :rtype: list[V1EnvVar] )r#)r5r6r6r7r s zV1Container.envcCs ||_dS)z Sets the env of this V1Container. List of environment variables to set in the container. Cannot be updated. :param env: The env of this V1Container. :type: list[V1EnvVar] N)r#)r5r r6r6r7r s cCs|jS)a# Gets the env_from of this V1Container. List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated. :return: The env_from of this V1Container. :rtype: list[V1EnvFromSource] )r$)r5r6r6r7rs zV1Container.env_fromcCs ||_dS)a* Sets the env_from of this V1Container. List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated. :param env_from: The env_from of this V1Container. :type: list[V1EnvFromSource] N)r$)r5rr6r6r7rs cCs|jS)z Gets the image of this V1Container. Docker image name. More info: https://kubernetes.io/docs/concepts/containers/images :return: The image of this V1Container. :rtype: str )r%)r5r6r6r7rs zV1Container.imagecCs|dkrtd||_dS)z Sets the image of this V1Container. Docker image name. More info: https://kubernetes.io/docs/concepts/containers/images :param image: The image of this V1Container. :type: str Nz-Invalid value for `image`, must not be `None`) ValueErrorr%)r5rr6r6r7rs cCs|jS)a Gets the image_pull_policy of this V1Container. Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images :return: The image_pull_policy of this V1Container. :rtype: str )r&)r5r6r6r7rs zV1Container.image_pull_policycCs ||_dS)a Sets the image_pull_policy of this V1Container. Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images :param image_pull_policy: The image_pull_policy of this V1Container. :type: str N)r&)r5rr6r6r7rs cCs|jS)z Gets the lifecycle of this V1Container. Actions that the management system should take in response to container lifecycle events. Cannot be updated. :return: The lifecycle of this V1Container. :rtype: V1Lifecycle )r')r5r6r6r7rs zV1Container.lifecyclecCs ||_dS)a Sets the lifecycle of this V1Container. Actions that the management system should take in response to container lifecycle events. Cannot be updated. :param lifecycle: The lifecycle of this V1Container. :type: V1Lifecycle N)r')r5rr6r6r7rs cCs|jS)a^ Gets the liveness_probe of this V1Container. Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes :return: The liveness_probe of this V1Container. :rtype: V1Probe )r()r5r6r6r7rs zV1Container.liveness_probecCs ||_dS)ak Sets the liveness_probe of this V1Container. Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes :param liveness_probe: The liveness_probe of this V1Container. :type: V1Probe N)r()r5rr6r6r7rs cCs|jS)a Gets the name of this V1Container. Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated. :return: The name of this V1Container. :rtype: str )r))r5r6r6r7rs zV1Container.namecCs|dkrtd||_dS)a Sets the name of this V1Container. Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated. :param name: The name of this V1Container. :type: str Nz,Invalid value for `name`, must not be `None`)r9r))r5rr6r6r7r)s cCs|jS)a Gets the ports of this V1Container. List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default "0.0.0.0" address inside a container will be accessible from the network. Cannot be updated. :return: The ports of this V1Container. :rtype: list[V1ContainerPort] )r*)r5r6r6r7r7s zV1Container.portscCs ||_dS)a# Sets the ports of this V1Container. List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default "0.0.0.0" address inside a container will be accessible from the network. Cannot be updated. :param ports: The ports of this V1Container. :type: list[V1ContainerPort] N)r*)r5rr6r6r7rBs cCs|jS)a~ Gets the readiness_probe of this V1Container. Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes :return: The readiness_probe of this V1Container. :rtype: V1Probe )r+)r5r6r6r7rNs zV1Container.readiness_probecCs ||_dS)a Sets the readiness_probe of this V1Container. Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes :param readiness_probe: The readiness_probe of this V1Container. :type: V1Probe N)r+)r5rr6r6r7rYs cCs|jS)a2 Gets the resources of this V1Container. Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources :return: The resources of this V1Container. :rtype: V1ResourceRequirements )r,)r5r6r6r7res zV1Container.resourcescCs ||_dS)a: Sets the resources of this V1Container. Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources :param resources: The resources of this V1Container. :type: V1ResourceRequirements N)r,)r5rr6r6r7rps cCs|jS)ar Gets the security_context of this V1Container. Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md :return: The security_context of this V1Container. :rtype: V1SecurityContext )r-)r5r6r6r7r|s zV1Container.security_contextcCs ||_dS)a Sets the security_context of this V1Container. Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md :param security_context: The security_context of this V1Container. :type: V1SecurityContext N)r-)r5rr6r6r7rs cCs|jS)a: Gets the stdin of this V1Container. Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false. :return: The stdin of this V1Container. :rtype: bool )r.)r5r6r6r7rs zV1Container.stdincCs ||_dS)a> Sets the stdin of this V1Container. Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false. :param stdin: The stdin of this V1Container. :type: bool N)r.)r5rr6r6r7rs cCs|jS)a Gets the stdin_once of this V1Container. Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false :return: The stdin_once of this V1Container. :rtype: bool )r/)r5r6r6r7rs zV1Container.stdin_oncecCs ||_dS)a Sets the stdin_once of this V1Container. Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false :param stdin_once: The stdin_once of this V1Container. :type: bool N)r/)r5rr6r6r7rs cCs|jS)aE Gets the termination_message_path of this V1Container. Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated. :return: The termination_message_path of this V1Container. :rtype: str )r0)r5r6r6r7rs z$V1Container.termination_message_pathcCs ||_dS)a\ Sets the termination_message_path of this V1Container. Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated. :param termination_message_path: The termination_message_path of this V1Container. :type: str N)r0)r5rr6r6r7rs cCs|jS)ah Gets the termination_message_policy of this V1Container. Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated. :return: The termination_message_policy of this V1Container. :rtype: str )r1)r5r6r6r7rs z&V1Container.termination_message_policycCs ||_dS)a Sets the termination_message_policy of this V1Container. Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated. :param termination_message_policy: The termination_message_policy of this V1Container. :type: str N)r1)r5rr6r6r7rs cCs|jS)z Gets the tty of this V1Container. Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false. :return: The tty of this V1Container. :rtype: bool )r2)r5r6r6r7rs zV1Container.ttycCs ||_dS)z Sets the tty of this V1Container. Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false. :param tty: The tty of this V1Container. :type: bool N)r2)r5rr6r6r7rs cCs|jS)z Gets the volume_mounts of this V1Container. Pod volumes to mount into the container's filesystem. Cannot be updated. :return: The volume_mounts of this V1Container. :rtype: list[V1VolumeMount] )r3)r5r6r6r7rs zV1Container.volume_mountscCs ||_dS)z Sets the volume_mounts of this V1Container. Pod volumes to mount into the container's filesystem. Cannot be updated. :param volume_mounts: The volume_mounts of this V1Container. :type: list[V1VolumeMount] N)r3)r5rr6r6r7rs cCs|jS)a2 Gets the working_dir of this V1Container. Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated. :return: The working_dir of this V1Container. :rtype: str )r4)r5r6r6r7rs zV1Container.working_dircCs ||_dS)a< Sets the working_dir of this V1Container. Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated. :param working_dir: The working_dir of this V1Container. :type: str N)r4)r5rr6r6r7r(s cCsi}xt|jD]z\}}t||}t|trDttdd|||<qt|dr\|j||<qt|trttdd|j ||<q|||<qW|S)z8 Returns the model properties as a dict cSst|dr|jS|S)Nto_dict)hasattrr:)xr6r6r7>sz%V1Container.to_dict..r:cSs&t|ddr"|d|djfS|S)Nr:r)r;r:)itemr6r6r7r=Es) rrgetattr isinstancelistmapr;r:dictitems)r5resultattr_valuer6r6r7r:4s     zV1Container.to_dictcCs t|jS)z@ Returns the string representation of the model )rr:)r5r6r6r7to_strNszV1Container.to_strcCs|jS)z* For `print` and `pprint` )rJ)r5r6r6r7__repr__TszV1Container.__repr__cCst|tsdS|j|jkS)z8 Returns true if both objects are equal F)rAr__dict__)r5otherr6r6r7__eq__Zs zV1Container.__eq__cCs ||k S)z< Returns true if both objects are not equal r6)r5rMr6r6r7__ne__cszV1Container.__ne__)NNNNNNNNNNNNNNNNNNNN) __name__ __module__ __qualname____doc__r8propertyr setterr r rrrrrrrrrrrrrrrrrr:rJrKrNrOr6r6r6r7rs^ L                      r)rSpprintrsixrreobjectrr6r6r6r7 s