roverflow / vpn

An Ansible Collection to build, maintain and validate VPN tunnels across cloud providers and network appliances.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Network VPN Validated Content

CI OpenSSF Best Practices

This repository contains the network.vpn Ansible Collection.

Description

An Ansible Collection to build, maintain and validate VPN tunnels across cloud providers and network appliances. See Supported Providers section for more details.

Tested with Ansible

Tested with ansible-core >=2.15 releases.

Installation

To consume this Validated Content from Automation Hub, the following needs to be added to ansible.cfg:

[galaxy]
server_list = automation_hub

[galaxy_server.automation_hub]
url=https://cloud.redhat.com/api/automation-hub/
auth_url=https://sso.redhat.com/auth/realms/redhat-external/protocol/openid-connect/token
token=<SuperSecretToken>

Get the required token from the Automation Hub Web UI.

With this configured, simply run the following commands:

ansible-galaxy collection install network.vpn

Using this collection

Example 1

---
- name: Deploy and validate AWS and Azure tunnels
  hosts: localhost
  gather_facts: true
  tasks:
    - name: "Run network.vpn collection with specified operations"
      ansible.builtin.include_role:
        name: network.vpn.run
      vars:
        operations:
          - name: deploy
            vars:
              provider: aws
              configuration_file: aws.yaml

          - name: deploy
            vars:
              provider: azure
              configuration_file: azure.yaml

          - name: validate
            vars:
              provider: aws
              tunnel: 1
              session_status: UP

          - name: validate
            vars:
              provider: azure
              resource_group: VPN-RG
              vpn_connection_name: Azure-to-AWS
              session_status: Connected

Example 2

---
- name: Deploy and Validate CSR tunnels
  hosts: csr_gateways
  gather_facts: true
  tasks:
    - name: "Run network.vpn collection with specified operations"
      ansible.builtin.include_role:
        name: network.vpn.run
      vars:
        provider: csr
        operations:
          - name: deploy
            vars:
              configuration_file: "{{ inventory_hostname }}.yaml"

          - name: validate
            vars:
              tunnel: Tunnel0
              session_status: Connected

Supported providers

Provider Operations Operation Options
aws deploy Options
validate Options
azure deploy Options
validate Options
csr deploy Options
validate Options

Requirements

The following collections should be installed:

  • azure.azcollection
  • cisco.ios
  • community.aws

Code of Conduct

This collection follows the Ansible project's Code of Conduct. Please read and familiarize yourself with this document.

Release notes

Release notes are available here.

Licensing

GNU General Public License v3.0 or later.

See COPYING to see the full text.

About

An Ansible Collection to build, maintain and validate VPN tunnels across cloud providers and network appliances.

License:GNU General Public License v3.0


Languages

Language:Python 100.0%