Releases: Juniper/ansible-junos-stdlib
Release 1.2.0
New Features
Added junos_srx_cluster
-
SRX devices can be joined or removed from a cluster
Example
-junos_srx_cluster: host={{ inventory_hostname }} console="--port={{ serial }}" cluster_enable=true logfile=cluster.log cluster_id={{ cluster_id }} node={{ node_id }} -junos_srx_cluster: host={{ inventory_hostname }} cluster_enable=false logfile=cluster.log
Added junos_get_config
-
Configuration can be retrieved from a device and stored as a file. Supports text (default) and XML format. Configuration
filterandoptionssupported.Example
- junos_get_config: host: "{{ inventory_hostname }}" logfile: get_config.log dest: "{{ inventory_hostname }}.xml" format: xml filter: "interfaces" options: {inherit: inherit, groups: groups}
Added junos_rollback
-
Configuration will be rolled back and committed to Rollback Id provided. Module supports commit comments and confirm.
Example
- junos_rollback: host: "{{ inventory_hostname }}" logfile=rollback.log diffs_file=rollback.diff rollback=1 comment="Rolled back by Ansible" confirm=5
Added junos_commit
-
Execute a commit independently of loading a configuration.
Example
- junos_commit: host: "{{ inventory_hostname }}" logfile=changes.log comment="Non load commit"
Updated junos_install_config
-
Now supports
Load Replace -
Now supports
Commit ConfirmedExample
- junos_install_config: host={{ inventory_hostname }} file=snmp.conf replace=yes confirm=5
Bugs Fixed
junos_install_config
- Underlying PyEZ exceptions were not being properly captured and logged. #56
- Warnings (RpcError) were not triggering rollback. Warning will now prevent a configuration from loading. (Per PyEZ functionality). #58
2015-07-29 17:12:48,505:CONFIG:pabst.englab.juniper.net:pushing file: /home/rsherman/workspace/warning.set
2015-07-29 17:12:48,505:CONFIG:pabst.englab.juniper.net:taking lock
2015-07-29 17:12:48,828:CONFIG:pabst.englab.juniper.net:loading config
2015-07-29 17:12:49,980:CONFIG:pabst.englab.juniper.net:doing a commit-check, please be patient
2015-07-29 17:12:51,467:CONFIG:pabst.englab.juniper.net:Unable to commit configuration: CommitError(edit_path: [edit security policies from-zone corp to-zone], bad_element: corp, message: mgd: Security zone must be defined)
Release 1.1.0
New Features
Add Ability to specify NETCONF Port
-
User can specify port other than default 830
Example
junos_install_config: host={{ inventory_hostname }} user=user passwd=pass port=22 file=load.conf
Commit comment junos_install_config
-
Add ability to specify a comment with config commit
Example
- junos_install_config: host={{ inventory_hostname }} file=banner.conf comment="configured by ansible"
Check mode added to junos_install_config and junos_get_facts
- Allows use of --check when executing ansible-playbook
- junos_get_facts will return facts as normal
- junos_install_config will load config, commit check and automatically rollback on exit.
Write configuration diff to file junos_install_config
-
Allows user to specify a file to write configuration diff to
Example
junos_install_config: host={{ inventory_hostname }} file=load.conf diffs_file=diff.log
Bugs Fixed
Rename facts 2RE to has_2RE
- Per Ansible convention all variables should start with a letter.
Console mode logging
- Underlying netconify errors were not captured
junos_install_config Exception Handling
-
Capture and log PyEZ ConfigLoadError and CommitError
2015-01-15 13:13:33,861:CONFIG:device:connecting to host: regress@device:22 2015-01-15 13:13:40,657:CONFIG:device:pushing file: /home/rsherman/workspace/bad-script.conf 2015-01-15 13:13:40,657:CONFIG:device:taking lock 2015-01-15 13:13:40,878:CONFIG:device:loading config 2015-01-15 13:13:41,101:CONFIG:device:unable to load config:error,op1,syntax error 2015-01-15 13:13:41,101:CONFIG:device:Unable to make changes
Release 1.0.0
Production Release 1.0.0
Early Adopter Release 0.4.0
Bugfix:
Updates for junos_install_config to do merge by default via Netconf
Introduced version 1.6
Early Adopter Release 0.3.0
Test release to confirm Autodoc feature does not break Galaxy Install.
Early Adopter Release 0.2.0
This is the first release into Ansible Galaxy. This is for testing, and changes are expected.
Early Adopter Release 0.1.0
This is the first early adopter release of Junos modules for Ansible, tested against ansible 1.5. All modules are documented per-Ansible style guides. This code has not been submitted to ansible-core at this time.