PARALLAX

intersight_iscsi_boot_policy

Manage iSCSI Boot Policies for Cisco Intersight

Collection: cisco.intersight

Full Name: cisco.intersight.intersight_iscsi_boot_policy

Synopsis

Manage iSCSI Boot Policies for Cisco Intersight

Parameters

NameTypeRequiredDefaultDescription
api_private_keystringFilename (absolute path) or string of PEM formatted private key data to be used for Intersight API authentication. If a string is used, Ansible vault should be used to encrypt string data. Ex. ansible-vault encrypt_string –vault-id tme@/Users/dsoper/Documents/vault_password_file ‘—–BEGIN EC PRIVATE KEY—– —–END EC PRIVATE KEY—–’ If not set, the value of the INTERSIGHT_API_PRIVATE_KEY environment variable is used. Required if I(api_bearer_token) is not provided. Secret value; omitted from logs and results.
api_uristringhttps://intersight.com/api/v1URI used to access the Intersight API. If not set, the value of the INTERSIGHT_API_URI environment variable is used.
api_key_idstringPublic API Key ID associated with the private key. If not set, the value of the INTERSIGHT_API_KEY_ID environment variable is used. Required if I(api_bearer_token) is not provided.
api_bearer_tokenstringBearer token for OAuth2 authentication with the Intersight API. When provided, I(api_key_id) and I(api_private_key) are not required and the C(cryptography) Python library is not needed. If not set, the value of the INTERSIGHT_API_BEARER_TOKEN environment variable is used. Secret value; omitted from logs and results.
validate_certsbooltrueBoolean control for verifying the api_uri TLS certificate
use_proxybooltrueIf C(no), it will not use a proxy, even if one is defined in an environment variable on the target hosts.
statestringpresentIf C(present), will verify the resource is present and will create if needed. If C(absent), will verify the resource is absent and will delete if needed. Choices: present, absent
organizationstringdefaultThe name of the Organization this resource is assigned to. Policies created within a Custom Organization are applicable only to devices in the same Organization. Use ‘default’ for the default organization.
namestringyesThe name assigned to the iSCSI Boot Policy. Must be unique within the organization. The name must be between 1 and 64 alphanumeric characters, allowing special characters :-_.
descriptionstringThe user-defined description for the iSCSI Boot Policy. Description can contain letters(a-z, A-Z), numbers(0-9), hyphen(-), period(.), colon(:), or an underscore(_).
tagslistList of tags in Key: Value: format.
iscsi_ip_typestringipv4Type of the IP address requested for iSCSI vNIC - IPv4/IPv6. ipv4 supports both auto and static target source types. ipv6 only supports static target source type (not auto). Both ipv4 and ipv6 support dhcp, pool, and static initiator IP sources. Choices: ipv4, ipv6
target_source_typestringstaticTarget discovery method. auto - Automatic target discovery using DHCP vendor ID/IQN. static - Manual target configuration using target policies. Choices: auto, static
auto_targetvendor_namestringAuto target interface that is represented via the Initiator name or the DHCP vendor ID. The vendor ID can be up to 64 characters. Required when target_source_type is auto and iscsi_ip_type is ipv4.
iscsi_adapter_policy_namestringRelationship to the iSCSI Adapter Policy. Name of the iSCSI adapter policy to associate with this boot policy. Optional for all configurations.
primary_target_policy_namestringSpecifies Target Profile information for iSCSI Boot. Name of the primary iSCSI static target policy. Required when target_source_type is static.
secondary_target_policy_namestringSpecifies Target Profile information for iSCSI Boot. Optional when target_source_type is static.
chapdictCHAP authentication parameters for iSCSI Target. Provide user_id and password to enable CHAP authentication. Leave empty or omit to disable CHAP authentication. Nested options: user_id (str) required; password (str) required secret
mutual_chapdictMutual CHAP authentication parameters for iSCSI Initiator. Two-way CHAP mechanism. Provide user_id and password to enable Mutual CHAP authentication. Leave empty or omit to disable Mutual CHAP authentication. Nested options: user_id (str) required; password (str) required secret
initiator_ip_sourcestringdhcpMethod for assigning initiator IP address. dhcp - Obtain IP address automatically via DHCP. pool - Use an IP pool for address assignment. static - Manually configure static IP address. Choices: dhcp, pool, static
initiator_ip_pool_namestringName of the IP pool to use for initiator IP address assignment. Required when initiator_ip_source is pool.
initiator_static_ipv4_addressstringStatic IPv4 address provided for iSCSI Initiator. Required when initiator_ip_source is static and iscsi_ip_type is ipv4.
initiator_static_ipv4_netmaskstringA subnet mask is a 32-bit number that masks an IP address and divides the IP address into network address and host address. Required when initiator_ip_source is static and iscsi_ip_type is ipv4.
initiator_static_ipv4_gatewaystringIP address of the default IPv4 gateway. Required when initiator_ip_source is static and iscsi_ip_type is ipv4.
initiator_static_ipv4_primary_dnsstringIP Address of the primary Domain Name System (DNS) server. Optional when initiator_ip_source is static and iscsi_ip_type is ipv4.
initiator_static_ipv4_secondary_dnsstringIP Address of the secondary Domain Name System (DNS) server. Optional when initiator_ip_source is static and iscsi_ip_type is ipv4.
initiator_static_ipv6_addressstringStatic IPv6 address provided for iSCSI Initiator. Required when initiator_ip_source is static and iscsi_ip_type is ipv6.
initiator_static_ipv6_prefixintThe integer length of the prefix that masks the IP address and divides it into network and host addresses. Required when initiator_ip_source is static and iscsi_ip_type is ipv6.
initiator_static_ipv6_gatewaystringIP address of the default IPv6 gateway. Required when initiator_ip_source is static and iscsi_ip_type is ipv6.

Example

yaml
- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    auto_targetvendor_name: iqn.1991-05.com.cisco
    description: iSCSI boot policy with auto discovery
    initiator_ip_source: dhcp
    iscsi_adapter_policy_name: iscsi-adapter-policy
    iscsi_ip_type: ipv4
    name: iscsi-boot-auto
    organization: default
    state: present
    target_source_type: auto
  name: Create iSCSI Boot Policy with Auto discovery (IPv4)

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    chap:
        password: chappassword123
        user_id: chapuser
    description: iSCSI boot policy with static targets
    initiator_ip_source: dhcp
    iscsi_ip_type: ipv4
    mutual_chap:
        password: mutualpassword123
        user_id: mutualuser
    name: iscsi-boot-static-dhcp
    organization: default
    primary_target_policy_name: primary-target-policy
    secondary_target_policy_name: secondary-target-policy
    state: present
    target_source_type: static
  name: Create iSCSI Boot Policy with Static targets and DHCP initiator (IPv4)

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    description: iSCSI boot policy with IP pool
    initiator_ip_pool_name: iscsi-ip-pool
    initiator_ip_source: pool
    iscsi_ip_type: ipv4
    name: iscsi-boot-pool
    organization: default
    primary_target_policy_name: primary-target-policy
    state: present
    target_source_type: static
  name: Create iSCSI Boot Policy with Pool-based initiator IP

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    description: iSCSI boot policy with static IPv4
    initiator_ip_source: static
    initiator_static_ipv4_address: 192.168.1.100
    initiator_static_ipv4_gateway: 192.168.1.1
    initiator_static_ipv4_netmask: 255.255.255.0
    initiator_static_ipv4_primary_dns: 8.8.8.8
    initiator_static_ipv4_secondary_dns: 8.8.4.4
    iscsi_ip_type: ipv4
    name: iscsi-boot-static-ipv4
    organization: default
    primary_target_policy_name: primary-target-policy
    state: present
    tags:
        - Key: Environment
          Value: Production
    target_source_type: static
  name: Create iSCSI Boot Policy with Static IPv4 configuration

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    description: iSCSI boot policy with static IPv6
    initiator_ip_source: static
    initiator_static_ipv6_address: 2001:db8::1
    initiator_static_ipv6_gateway: 2001:db8::ffff
    initiator_static_ipv6_prefix: 64
    iscsi_ip_type: ipv6
    name: iscsi-boot-static-ipv6
    organization: default
    primary_target_policy_name: primary-target-policy-ipv6
    state: present
    target_source_type: static
  name: Create iSCSI Boot Policy with Static IPv6 configuration

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    description: iSCSI boot policy with IPv6 DHCP
    initiator_ip_source: dhcp
    iscsi_ip_type: ipv6
    name: iscsi-boot-ipv6-dhcp
    organization: default
    primary_target_policy_name: primary-target-policy-ipv6
    state: present
    target_source_type: static
  name: Create iSCSI Boot Policy with IPv6 DHCP initiator

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    description: iSCSI boot policy with IPv6 pool
    initiator_ip_pool_name: ipv6-ip-pool
    initiator_ip_source: pool
    iscsi_ip_type: ipv6
    name: iscsi-boot-ipv6-pool
    organization: default
    primary_target_policy_name: primary-target-policy-ipv6
    state: present
    target_source_type: static
  name: Create iSCSI Boot Policy with IPv6 Pool initiator

- cisco.intersight.intersight_iscsi_boot_policy:
    api_key_id: '{{ api_key_id }}'
    api_private_key: '{{ api_private_key }}'
    name: iscsi-boot-auto
    state: absent
  name: Delete iSCSI Boot Policy
Search
    ↑ ↓ move↵ openesc close