3 fYE@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@seZdZdZd9ddZeddZejddZedd 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-Zd/d0Zd1d2Zd3d4Zd5d6Zd7d8ZdS):V1beta1PodSecurityPolicySpeczw NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. NcCsddddddddddddddd|_d d d d d dddddddddd|_||_||_||_||_||_||_||_||_ | |_ | |_ | |_ | |_ | |_||_dS)aR V1beta1PodSecurityPolicySpec - 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]V1beta1FSGroupStrategyOptionsboolzlist[V1beta1HostPortRange]V1beta1RunAsUserStrategyOptionsV1beta1SELinuxStrategyOptions(V1beta1SupplementalGroupsStrategyOptions)allowed_capabilitiesdefault_add_capabilitiesfs_grouphost_ipc host_networkhost_pid host_ports privilegedread_only_root_filesystemrequired_drop_capabilities run_as_userse_linuxsupplemental_groupsvolumesZallowedCapabilitiesZdefaultAddCapabilitiesfsGrouphostIPC hostNetworkhostPIDZ hostPortsrreadOnlyRootFilesystemZrequiredDropCapabilities runAsUserZseLinuxsupplementalGroupsrN) swagger_types attribute_map_allowed_capabilities_default_add_capabilities _fs_group _host_ipc _host_network _host_pid _host_ports _privileged_read_only_root_filesystem_required_drop_capabilities _run_as_user _se_linux_supplemental_groups_volumes)selfr r r r rrrrrrrrrrr0j/Users/olari/OneDrive/sandbox/awsBlog2/lambda/kubernetes/client/models/v1beta1_pod_security_policy_spec.py__init__sT   z%V1beta1PodSecurityPolicySpec.__init__cCs|jS)a Gets the allowed_capabilities of this V1beta1PodSecurityPolicySpec. AllowedCapabilities is a list of capabilities that can be requested to add to the container. Capabilities in this field may be added at the pod author's discretion. You must not list a capability in both AllowedCapabilities and RequiredDropCapabilities. :return: The allowed_capabilities of this V1beta1PodSecurityPolicySpec. :rtype: list[str] )r!)r/r0r0r1r Rs z1V1beta1PodSecurityPolicySpec.allowed_capabilitiescCs ||_dS)a Sets the allowed_capabilities of this V1beta1PodSecurityPolicySpec. AllowedCapabilities is a list of capabilities that can be requested to add to the container. Capabilities in this field may be added at the pod author's discretion. You must not list a capability in both AllowedCapabilities and RequiredDropCapabilities. :param allowed_capabilities: The allowed_capabilities of this V1beta1PodSecurityPolicySpec. :type: list[str] N)r!)r/r r0r0r1r ]s cCs|jS)a Gets the default_add_capabilities of this V1beta1PodSecurityPolicySpec. DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities. :return: The default_add_capabilities of this V1beta1PodSecurityPolicySpec. :rtype: list[str] )r")r/r0r0r1r is z5V1beta1PodSecurityPolicySpec.default_add_capabilitiescCs ||_dS)a Sets the default_add_capabilities of this V1beta1PodSecurityPolicySpec. DefaultAddCapabilities is the default set of capabilities that will be added to the container unless the pod spec specifically drops the capability. You may not list a capabiility in both DefaultAddCapabilities and RequiredDropCapabilities. :param default_add_capabilities: The default_add_capabilities of this V1beta1PodSecurityPolicySpec. :type: list[str] N)r")r/r r0r0r1r ts cCs|jS)a Gets the fs_group of this V1beta1PodSecurityPolicySpec. FSGroup is the strategy that will dictate what fs group is used by the SecurityContext. :return: The fs_group of this V1beta1PodSecurityPolicySpec. :rtype: V1beta1FSGroupStrategyOptions )r#)r/r0r0r1r s z%V1beta1PodSecurityPolicySpec.fs_groupcCs|dkrtd||_dS)a# Sets the fs_group of this V1beta1PodSecurityPolicySpec. FSGroup is the strategy that will dictate what fs group is used by the SecurityContext. :param fs_group: The fs_group of this V1beta1PodSecurityPolicySpec. :type: V1beta1FSGroupStrategyOptions Nz0Invalid value for `fs_group`, must not be `None`) ValueErrorr#)r/r r0r0r1r s cCs|jS)z Gets the host_ipc of this V1beta1PodSecurityPolicySpec. hostIPC determines if the policy allows the use of HostIPC in the pod spec. :return: The host_ipc of this V1beta1PodSecurityPolicySpec. :rtype: bool )r$)r/r0r0r1r s z%V1beta1PodSecurityPolicySpec.host_ipccCs ||_dS)z Sets the host_ipc of this V1beta1PodSecurityPolicySpec. hostIPC determines if the policy allows the use of HostIPC in the pod spec. :param host_ipc: The host_ipc of this V1beta1PodSecurityPolicySpec. :type: bool N)r$)r/r r0r0r1r s cCs|jS)a Gets the host_network of this V1beta1PodSecurityPolicySpec. hostNetwork determines if the policy allows the use of HostNetwork in the pod spec. :return: The host_network of this V1beta1PodSecurityPolicySpec. :rtype: bool )r%)r/r0r0r1rs z)V1beta1PodSecurityPolicySpec.host_networkcCs ||_dS)a Sets the host_network of this V1beta1PodSecurityPolicySpec. hostNetwork determines if the policy allows the use of HostNetwork in the pod spec. :param host_network: The host_network of this V1beta1PodSecurityPolicySpec. :type: bool N)r%)r/rr0r0r1rs cCs|jS)z Gets the host_pid of this V1beta1PodSecurityPolicySpec. hostPID determines if the policy allows the use of HostPID in the pod spec. :return: The host_pid of this V1beta1PodSecurityPolicySpec. :rtype: bool )r&)r/r0r0r1rs z%V1beta1PodSecurityPolicySpec.host_pidcCs ||_dS)z Sets the host_pid of this V1beta1PodSecurityPolicySpec. hostPID determines if the policy allows the use of HostPID in the pod spec. :param host_pid: The host_pid of this V1beta1PodSecurityPolicySpec. :type: bool N)r&)r/rr0r0r1rs cCs|jS)a  Gets the host_ports of this V1beta1PodSecurityPolicySpec. hostPorts determines which host port ranges are allowed to be exposed. :return: The host_ports of this V1beta1PodSecurityPolicySpec. :rtype: list[V1beta1HostPortRange] )r')r/r0r0r1rs z'V1beta1PodSecurityPolicySpec.host_portscCs ||_dS)a Sets the host_ports of this V1beta1PodSecurityPolicySpec. hostPorts determines which host port ranges are allowed to be exposed. :param host_ports: The host_ports of this V1beta1PodSecurityPolicySpec. :type: list[V1beta1HostPortRange] N)r')r/rr0r0r1rs cCs|jS)z Gets the privileged of this V1beta1PodSecurityPolicySpec. privileged determines if a pod can request to be run as privileged. :return: The privileged of this V1beta1PodSecurityPolicySpec. :rtype: bool )r()r/r0r0r1rs z'V1beta1PodSecurityPolicySpec.privilegedcCs ||_dS)z Sets the privileged of this V1beta1PodSecurityPolicySpec. privileged determines if a pod can request to be run as privileged. :param privileged: The privileged of this V1beta1PodSecurityPolicySpec. :type: bool N)r()r/rr0r0r1rs cCs|jS)a Gets the read_only_root_filesystem of this V1beta1PodSecurityPolicySpec. ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to. :return: The read_only_root_filesystem of this V1beta1PodSecurityPolicySpec. :rtype: bool )r))r/r0r0r1r s z6V1beta1PodSecurityPolicySpec.read_only_root_filesystemcCs ||_dS)a2 Sets the read_only_root_filesystem of this V1beta1PodSecurityPolicySpec. ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file system. If the container specifically requests to run with a non-read only root file system the PSP should deny the pod. If set to false the container may run with a read only root file system if it wishes but it will not be forced to. :param read_only_root_filesystem: The read_only_root_filesystem of this V1beta1PodSecurityPolicySpec. :type: bool N)r))r/rr0r0r1rs cCs|jS)ab Gets the required_drop_capabilities of this V1beta1PodSecurityPolicySpec. RequiredDropCapabilities are the capabilities that will be dropped from the container. These are required to be dropped and cannot be added. :return: The required_drop_capabilities of this V1beta1PodSecurityPolicySpec. :rtype: list[str] )r*)r/r0r0r1r#s z7V1beta1PodSecurityPolicySpec.required_drop_capabilitiescCs ||_dS)a{ Sets the required_drop_capabilities of this V1beta1PodSecurityPolicySpec. RequiredDropCapabilities are the capabilities that will be dropped from the container. These are required to be dropped and cannot be added. :param required_drop_capabilities: The required_drop_capabilities of this V1beta1PodSecurityPolicySpec. :type: list[str] N)r*)r/rr0r0r1r.s cCs|jS)a( Gets the run_as_user of this V1beta1PodSecurityPolicySpec. runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set. :return: The run_as_user of this V1beta1PodSecurityPolicySpec. :rtype: V1beta1RunAsUserStrategyOptions )r+)r/r0r0r1r:s z(V1beta1PodSecurityPolicySpec.run_as_usercCs|dkrtd||_dS)a2 Sets the run_as_user of this V1beta1PodSecurityPolicySpec. runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set. :param run_as_user: The run_as_user of this V1beta1PodSecurityPolicySpec. :type: V1beta1RunAsUserStrategyOptions Nz3Invalid value for `run_as_user`, must not be `None`)r3r+)r/rr0r0r1rEs cCs|jS)a Gets the se_linux of this V1beta1PodSecurityPolicySpec. seLinux is the strategy that will dictate the allowable labels that may be set. :return: The se_linux of this V1beta1PodSecurityPolicySpec. :rtype: V1beta1SELinuxStrategyOptions )r,)r/r0r0r1rSs z%V1beta1PodSecurityPolicySpec.se_linuxcCs|dkrtd||_dS)a Sets the se_linux of this V1beta1PodSecurityPolicySpec. seLinux is the strategy that will dictate the allowable labels that may be set. :param se_linux: The se_linux of this V1beta1PodSecurityPolicySpec. :type: V1beta1SELinuxStrategyOptions Nz0Invalid value for `se_linux`, must not be `None`)r3r,)r/rr0r0r1r^s cCs|jS)aT Gets the supplemental_groups of this V1beta1PodSecurityPolicySpec. SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext. :return: The supplemental_groups of this V1beta1PodSecurityPolicySpec. :rtype: V1beta1SupplementalGroupsStrategyOptions )r-)r/r0r0r1rls z0V1beta1PodSecurityPolicySpec.supplemental_groupscCs|dkrtd||_dS)af Sets the supplemental_groups of this V1beta1PodSecurityPolicySpec. SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext. :param supplemental_groups: The supplemental_groups of this V1beta1PodSecurityPolicySpec. :type: V1beta1SupplementalGroupsStrategyOptions Nz;Invalid value for `supplemental_groups`, must not be `None`)r3r-)r/rr0r0r1rws cCs|jS)a Gets the volumes of this V1beta1PodSecurityPolicySpec. volumes is a white list of allowed volume plugins. Empty indicates that all plugins may be used. :return: The volumes of this V1beta1PodSecurityPolicySpec. :rtype: list[str] )r.)r/r0r0r1rs z$V1beta1PodSecurityPolicySpec.volumescCs ||_dS)a Sets the volumes of this V1beta1PodSecurityPolicySpec. volumes is a white list of allowed volume plugins. Empty indicates that all plugins may be used. :param volumes: The volumes of this V1beta1PodSecurityPolicySpec. :type: list[str] N)r.)r/rr0r0r1rs 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)hasattrr4)xr0r0r1sz6V1beta1PodSecurityPolicySpec.to_dict..r4cSs&t|ddr"|d|djfS|S)Nr4r)r5r4)itemr0r0r1r7s) rrgetattr isinstancelistmapr5r4dictitems)r/resultattr_valuer0r0r1r4s     z$V1beta1PodSecurityPolicySpec.to_dictcCs t|jS)z@ Returns the string representation of the model )rr4)r/r0r0r1to_strsz#V1beta1PodSecurityPolicySpec.to_strcCs|jS)z* For `print` and `pprint` )rD)r/r0r0r1__repr__sz%V1beta1PodSecurityPolicySpec.__repr__cCst|tsdS|j|jkS)z8 Returns true if both objects are equal F)r;r__dict__)r/otherr0r0r1__eq__s z#V1beta1PodSecurityPolicySpec.__eq__cCs ||k S)z< Returns true if both objects are not equal r0)r/rGr0r0r1__ne__sz#V1beta1PodSecurityPolicySpec.__ne__)NNNNNNNNNNNNNN)__name__ __module__ __qualname____doc__r2propertyr setterr r r rrrrrrrrrrr4rDrErHrIr0r0r0r1rsF :                r)rMpprintrsixrreobjectrr0r0r0r1 s