Skip to content

Commit 3f1a4b6

Browse files
samiiblhercot
authored andcommitted
[bug_fix] Updated README to match RedHat's ansible collection template.
1 parent f43e192 commit 3f1a4b6

File tree

1 file changed

+111
-46
lines changed

1 file changed

+111
-46
lines changed

README.md

+111-46
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,106 @@
11
# ansible-nd
22

3+
## Description
4+
35
The `ansible-nd` project provides an Ansible collection for managing and automating your Cisco Nexus Dashboard.
46
It consists of a set of plugins, modules and roles for performing tasks related to Cisco Nexus Dashboard.
57

6-
This collection has been tested and supports Nexus Dahsboard (ND) 2.0+.
7-
Modules supporting new features introduced in ND API in specific ND versions might not be supported in earlier ND releases.
8-
9-
*Note: This collection is not compatible with versions of Ansible before v2.8.*
8+
See the [cisco.nd collection index](https://galaxy.ansible.com/ui/repo/published/cisco/nd/content/) for a full list of modules and plugins.
109

1110
## Requirements
12-
- Ansible (ansible-core) v2.15 or newer
13-
- Python 3.9 or newer
1411

15-
## Install
16-
Ansible must be installed
12+
- Ansible v2.15 or newer
13+
- Python v3.10 or newer
14+
15+
Follow the [Installing Ansible](https://docs.ansible.com/ansible/latest/installation_guide/intro_installation.html) guide for detailed instructions.
16+
17+
## Installation
18+
19+
Before using this collection, you need to install it with the Ansible Galaxy command-line tool:
20+
21+
```sh
22+
ansible-galaxy collection install cisco.nd
1723
```
18-
sudo pip install ansible
24+
25+
You can also include this collection in a `requirements.yml` file and install it with:
26+
27+
```sh
28+
ansible-galaxy collection install -r requirements.yml
1929
```
2030

21-
Install the collection
31+
Using the following `requirements.yml` format:
32+
33+
```yaml
34+
collections:
35+
- name: cisco.nd
2236
```
23-
ansible-galaxy collection install cisco.nd
37+
38+
Note that if you install any collections from Ansible Galaxy, they will not be upgraded automatically when you upgrade the Ansible package.
39+
To upgrade the collection to the latest available version, run the following command:
40+
41+
```sh
42+
ansible-galaxy collection install cisco.nd --upgrade
43+
```
44+
45+
You can also install a specific version of the collection. For example, to install version 1.0.0, use the following syntax:
46+
47+
```sh
48+
ansible-galaxy collection install cisco.nd:==1.0.0
2449
```
2550

26-
## Use
51+
See [using Ansible collections](https://docs.ansible.com/ansible/devel/user_guide/collections_using.html) for more details.
52+
53+
### Latest Build
54+
55+
Follow these instructions to get the latest collection.
56+
57+
#### First Approach - Build From Source Code
58+
59+
Clone the ansible-nd repository.
60+
61+
```sh
62+
git clone https://github.com/CiscoDevNet/ansible-nd.git
63+
```
64+
65+
Go to the ansible-nd directory
66+
67+
```sh
68+
cd ansible-nd
69+
```
70+
71+
Pull the latest master on your nd
72+
73+
```sh
74+
git pull origin master
75+
```
76+
77+
Build and Install a collection from source
78+
79+
```sh
80+
ansible-galaxy collection build --force
81+
ansible-galaxy collection install cisco-nd-* --force
82+
```
83+
84+
#### Second Approach - Download From Latest CI Build
85+
86+
Go to [ansible-nd Actions](https://github.com/CiscoDevNet/ansible-nd/actions/workflows/ansible-test.yml?query=branch%3Amaster) and select the latest CI build.
87+
88+
Under Artifacts download collection suffixed with the latest version of Ansible (eg. `collection-stable-2.17`) and unzip it using Terminal or Console.
89+
90+
*Note: The collection file is a zip file containing a tar.gz file. We recommend using CLI because some GUI-based unarchiver might unarchive both nested archives in one go.*
91+
92+
Install the unarchived tar.gz file
93+
94+
```sh
95+
ansible-galaxy collection install cisco-nd-1.0.0.tar.gz —-force
96+
```
97+
98+
## Use Cases
99+
27100
Once the collection is installed, you can use it in a playbook by specifying the full namespace path to the module, plugin and/or role.
101+
102+
### Get the ND version
103+
28104
```yaml
29105
- hosts: nd
30106
gather_facts: no
@@ -34,7 +110,9 @@ Once the collection is installed, you can use it in a playbook by specifying the
34110
cisco.nd.nd_version:
35111
state: query
36112
```
113+
37114
With the following inventory file:
115+
38116
```yaml
39117
[nd]
40118
nd1 ansible_host=10.0.0.1 ansible_user=admin ansible_ssh_pass="MySuperPassword"
@@ -48,6 +126,7 @@ ansible_httpapi_use_proxy=True
48126
```
49127

50128
You can also use the ND HTTPAPI connection plugin with your cisco.mso Ansible collection for MSO running on ND (MSO version >= 3.2) using the inventory file above.
129+
51130
```yaml
52131
- hosts: nd
53132
gather_facts: no
@@ -58,51 +137,37 @@ You can also use the ND HTTPAPI connection plugin with your cisco.mso Ansible co
58137
state: query
59138
```
60139
61-
## Update
62-
Getting the latest/nightly collection build
140+
## Testing
63141
64-
### First Approach
65-
Clone the ansible-nd repository.
66-
```
67-
git clone https://github.com/CiscoDevNet/ansible-nd.git
68-
```
142+
Testing is currently done manually during the development of each module.
143+
Automated integration testing for this collection will be added in the future.
69144
70-
Go to the ansible-nd directory
71-
```
72-
cd ansible-nd
73-
```
145+
## Contributing to this collection
74146
75-
Pull the latest master on your local repo
76-
```
77-
git pull origin master
78-
```
147+
Ongoing development efforts and contributions to this collection are tracked as issues in this repository.
79148
80-
Build and Install a collection from source
81-
```
82-
ansible-galaxy collection build --force
83-
ansible-galaxy collection install cisco-nd-* --force
84-
```
149+
We welcome community contributions to this collection. If you find problems, need an enhancement or need a new module, please open an issue or create a PR against the [Cisco Nexus Dashboard collection repository](https://github.com/CiscoDevNet/ansible-nd/issues).
85150
86-
### Second Approach
87-
Go to: https://github.com/CiscoDevNet/ansible-nd/actions
151+
## Support
88152
89-
Select the latest CI build
153+
This collection supports any ND version within the Last Day of Support (LDOS) date.
90154
91-
Under Artifacts download collection and unzip it using Terminal or Console.
155+
Certain modules and options in the collection are only available from specific versions of ND. The versions that a module or option supports are documented in the individual module documentation.
92156
93-
*Note: The collection file is a zip file containing a tar.gz file. We recommend using CLI because some GUI-based unarchiver might unarchive both nested archives in one go.*
157+
To find EOL announcements for ND versions, refer to the [End-of-Life and End-of-Sale Notices](https://www.cisco.com/c/en/us/products/data-center-analytics/nexus-dashboard/eos-eol-notice-listing.html) page.
94158
95-
Install the unarchived tar.gz file
96-
```
97-
ansible-galaxy collection install cisco-nd-*.tar.gz —-force
98-
```
159+
## Release Notes
99160
100-
### See Also:
161+
See the [Changelog](CHANGELOG.rst) for full release notes.
101162
102-
* [Ansible Using collections](https://docs.ansible.com/ansible/latest/user_guide/collections_using.html) for more details.
163+
## Related Information
103164
104-
## Contributing to this collection
165+
For further information, refer to the following:
105166
106-
Ongoing development efforts and contributions to this collection are tracked as issues in this repository.
167+
- [Nexus Dashboard Overview](https://www.cisco.com/site/us/en/products/networking/cloud-networking/nexus-platform/index.html)
168+
- [Nexus Dashboard Support Documentation](https://www.cisco.com/c/en/us/support/data-center-analytics/nexus-dashboard/series.html)
169+
- [Nexus Dashboard API Documentation](https://developer.cisco.com/docs/nexus-dashboard/latest/introduction/#introduction)
107170
108-
We welcome community contributions to this collection. If you find problems, need an enhancement or need a new module, please open an issue or create a PR against the [Cisco Nexus Dashboard collection repository](https://github.com/CiscoDevNet/ansible-nd/issues).
171+
## License Information
172+
173+
This collection is licensed under the [GNU General Public License v3.0](LICENSE)

0 commit comments

Comments
 (0)