Use the following commands to install the Ansible Galaxy for Fortinet Collection. It is possible to install other collections as well by referring to this document. This article will demonstrate two examples: the FortiOS and FortiManager collection modules.
apt-get update apt-get install ansible ansible-galaxy collection install <Community Authors>.<Collection Name>
ansible-galaxy collection install fortinet.fortios <-- Install the FortiOS collection.
ansible-galaxy collection install fortinet.fortimanager <-- Install the FortiManager collection.
Sample installation output:
ansible-galaxy collection install fortinet.fortios Starting galaxy collection install process Process install dependency map Starting collection install process Downloading https://galaxy.ansible.com/download/fortinet-fortios-2.3.0.tar.gz to /root/.ansible/tmp/ansible-local-10381firwanm9/tmp87t8u58d/fortinet-fortios-2.3.0-iu893nym Installing 'fortinet.fortios:2.3.0' to '/root/.ansible/collections/ansible_collections/fortinet/fortios' Downloading https://galaxy.ansible.com/download/ansible-netcommon-5.1.2.tar.gz to /root/.ansible/tmp/ansible-local-10381firwanm9/tmp87t8u58d/ansible-netcommon-5.1.2-8lxo94b_ fortinet.fortios:2.3.0 was installed successfully Downloading https://galaxy.ansible.com/download/ansible-utils-2.10.3.tar.gz to /root/.ansible/tmp/ansible-local-10381firwanm9/tmp87t8u58d/ansible-utils-2.10.3-pww4s6cj Installing 'ansible.netcommon:5.1.2' to '/root/.ansible/collections/ansible_collections/ansible/netcommon' ansible.netcommon:5.1.2 was installed successfully Installing 'ansible.utils:2.10.3' to '/root/.ansible/collections/ansible_collections/ansible/utils' ansible.utils:2.10.3 was installed successfully
ansible-galaxy collection install fortinet.fortimanager Starting galaxy collection install process Process install dependency map Starting collection install process Downloading https://galaxy.ansible.com/download/fortinet-fortimanager-2.2.0.tar.gz to /root/.ansible/tmp/ansible-local-10725w6dnrkyp/tmp4ysbtplv/fortinet-fortimanager-2.2.0-lm_d7r9t Installing 'fortinet.fortimanager:2.2.0' to '/root/.ansible/collections/ansible_collections/fortinet/fortimanager' fortinet.fortimanager:2.2.0 was installed successfully 'ansible.netcommon:5.1.2' is already installed, skipping. 'ansible.utils:2.10.3' is already installed, skipping.
Use the following command to verify the installed collections.
ansible-galaxy collection list
Sample output:
ansible-galaxy collection list /usr/lib/python3/dist-packages/ansible_collections Collection Version ----------------------------- ------- amazon.aws 5.5.1 ansible.netcommon 4.1.0 ansible.posix 1.5.4 ansible.utils 2.10.3 ansible.windows 1.14.0 arista.eos 6.0.1 awx.awx 21.14.0 azure.azcollection 1.16.0 check_point.mgmt 4.0.0 chocolatey.chocolatey 1.4.0 cisco.aci 2.6.0 cisco.asa 4.0.1 cisco.dnac 6.7.2 cisco.intersight 1.0.27 cisco.ios 4.6.1 cisco.iosxr 4.1.0 cisco.ise 2.5.12 cisco.meraki 2.15.1 cisco.mso 2.4.0 cisco.nso 1.0.3 cisco.nxos 4.4.0 cisco.ucs 1.8.0 cloud.common 2.1.3 cloudscale_ch.cloud 2.3.1 community.aws 5.5.0 community.azure 2.0.0 community.ciscosmb 1.0.6 community.crypto 2.14.0 community.digitalocean 1.23.0 community.dns 2.5.5 community.docker 3.4.7 community.fortios 1.0.0 community.general 6.6.2 community.google 1.0.0 community.grafana 1.5.4 community.hashi_vault 4.2.1 community.hrobot 1.8.0 community.libvirt 1.2.0 community.mongodb 1.6.0 community.mysql 3.7.2 community.network 5.0.0 community.okd 2.3.0 community.postgresql 2.4.2 community.proxysql 1.5.1 community.rabbitmq 1.2.3 community.routeros 2.8.2 community.sap 1.0.0 community.sap_libs 1.4.1 community.skydive 1.0.0 community.sops 1.6.2 community.vmware 3.7.0 community.windows 1.13.0 community.zabbix 1.9.3 containers.podman 1.10.2 cyberark.conjur 1.2.0 cyberark.pas 1.0.19 dellemc.enterprise_sonic 2.0.0 dellemc.openmanage 6.3.0 dellemc.os10 1.1.1 dellemc.os6 1.0.7 dellemc.os9 1.0.4 dellemc.powerflex 1.6.0 dellemc.unity 1.6.0 f5networks.f5_modules 1.25.0 fortinet.fortimanager 2.2.0 fortinet.fortios 2.3.0 frr.frr 2.0.2 gluster.gluster 1.0.2 google.cloud 1.1.3 grafana.grafana 1.1.1 hetzner.hcloud 1.11.0 hpe.nimble 1.1.4 ibm.qradar 2.1.0 ibm.spectrum_virtualize 1.12.0 infinidat.infinibox 1.3.12 infoblox.nios_modules 1.5.0 inspur.ispim 1.3.0 inspur.sm 2.3.0 junipernetworks.junos 4.1.0 kubernetes.core 2.4.0 lowlydba.sqlserver 1.3.1 mellanox.onyx 1.0.0 microsoft.ad 1.2.0 netapp.aws 21.7.0 netapp.azure 21.10.0 netapp.cloudmanager 21.22.0 netapp.elementsw 21.7.0 netapp.ontap 22.7.0 netapp.storagegrid 21.11.1 netapp.um_info 21.8.0 netapp_eseries.santricity 1.4.0 netbox.netbox 3.13.0 ngine_io.cloudstack 2.3.0 ngine_io.exoscale 1.0.0 ngine_io.vultr 1.1.3 openstack.cloud 1.10.0 openvswitch.openvswitch 2.1.1 ovirt.ovirt 2.4.1 purestorage.flasharray 1.19.1 purestorage.flashblade 1.11.0 purestorage.fusion 1.5.0 sensu.sensu_go 1.13.2 splunk.es 2.1.0 t_systems_mms.icinga_director 1.33.1 theforeman.foreman 3.11.0 vmware.vmware_rest 2.3.1 vultr.cloud 1.8.0 vyos.vyos 4.1.0 wti.remote 1.0.5
/root/.ansible/collections/ansible_collections Collection Version --------------------- ------- ansible.netcommon 5.1.2 ansible.utils 2.10.3 fortinet.fortimanager 2.2.0 fortinet.fortios 2.3.0
|