Skip to content

Latest commit

 

History

History
50 lines (41 loc) · 2.09 KB

README.md

File metadata and controls

50 lines (41 loc) · 2.09 KB

Deploy

Overview

The deploy role will read the OSPF facts from the provided/default or remote inventory and deploy the changes onto the appliances. It enables users to read the config as host_vars from a local or remote data store and deploy network configurations if any changes are found. This role is designed to ensure that network configurations remain consistent and compliant across devices.

Features

  • Read network configuration data from local or remote repositories.
  • Deploy configurations only when changes are detected.
  • Support for integration with Git repositories for version control.

Variables

Variable Name Default Value Required Type Description Example
ansible_network_os "" no str Network OS to be used during deploy. "cisco.nxos.nxos"
data_store "" yes dict Defines the source of the configurations (local or remote). See usage example below.

Usage

Below is an example playbook demonstrating how to use the deploy role, where we will retrieve config from mentioned gh_scm_path and deploy on to the network.

---
- name: Deploy network configurations
  hosts: all
  gather_facts: true
  tasks:
    - name: Include deploy role
      ansible.builtin.include_role:
        name: network.ospf.deploy
      vars:
        data_store:
          scm:
            origin:
              url: "{{ gh_scm_path }}"
              token: "{{ gh_token }}"
              user:
                name: "{{ gh_username }}"
                email: "{{ gh_user_email }}"

Example Output When the playbook is executed successfully, the output will show the configurations being deployed when output verbosity is debug mode.

License

GNU General Public License v3.0 or later. See LICENSE to see the full text.

Author Information

  • Ansible Network Content Team