goldyfruit.ibmcloud_automation.ic_is_vpn_cidr (1.0.4) — module

Manage VPC VPN local or peer CIDRs on IBM Cloud.

| "added in version" 2.9 of goldyfruit.ibmcloud_automation"

Authors: Gaëtan Trellu (@goldyfruit)

preview | supported by community

Install collection

Install with ansible-galaxy collection install goldyfruit.ibmcloud_automation:==1.0.4


Add to requirements.yml

  collections:
    - name: goldyfruit.ibmcloud_automation
      version: 1.0.4

Description

This module adds the specified CIDR to the specified resource. A request body is not required, and if supplied, is ignored. This request succeeds if the CIDR already exists on the resource.


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Add peer CIDR to VPN connection
  ic_is_vpn_cidr:
    gateway: ibmcloud-vpn-gateway-baby
    connection: ibmcloud-vpn-connection-baby
    target: peer
    cidr: 10.0.0.0/24
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Add local CIDR to VPN connection
  ic_is_vpn_cidr:
    gateway: ibmcloud-vpn-gateway-baby
    connection: ibmcloud-vpn-connection-baby
    target: local
    cidr: 172.0.0.0/24
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Delete peer CIDR from VPN connection
  ic_is_vpn_cidr:
    gateway: ibmcloud-vpn-gateway-baby
    connection: ibmcloud-vpn-connection-baby
    target: peer
    cidr: 10.0.0.0/24
    state: absent
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Delete local CIDR from VPN connection
  ic_is_vpn_cidr:
    gateway: ibmcloud-vpn-gateway-baby
    connection: ibmcloud-vpn-connection-baby
    target: local
    cidr: 172.0.0.0/24
    state: absent

Inputs

    
cidr:
    description:
    - Restrict results to specific CIDR.
    required: true
    type: str

state:
    choices:
    - present
    - absent
    default: present
    description:
    - Should the resource be present or absent.
    type: str

target:
    choices:
    - local
    - peer
    default: local
    description:
    - Retrieve local or peer CIDRs.
    type: str

gateway:
    description:
    - VPN gateway ID or name.
    required: true
    type: str

connection:
    description:
    - VPN connection ID or name.
    required: true
    type: str