Skip to content

[FEATURE] junos.device.junos_acls | require 'log' attribute support in the junos,device,junos_acls module #843

Description

@chidanandpujar

Category

  • Bug
  • Feature
  • Task

Collection Namespace & Version

Field Value
Collection namespace juniper.device
Collection version 2.0.1
Collection install path /home/jcluser/.ansible/collections/ansible_collections
# How to find it:
ansible-galaxy collection list | grep -E 'juniper|junipernetworks'

Module / Plugin Details

Field Value
Module / plugin name juniper.device.junos_acls
Module version (if shown in output)
Plugin type module

Summary

Currently 'log' attribute is not supported in the published juniper.device.junos_acls module


Motivation

We are working for a customer and there is a requirement to support this attribute as it is explicitly available in
customer network service data model and junos network service need to align with it.


Proposed Playbook / Task Usage


  • name: Enable log condition for Firewall filters
    hosts: junos_devices
    gather_facts: no
    collections:

    • juniper.device # or junipernetworks.junos

    vars:

    tasks:

    • name: Enable log condition for Firewall filters
      juniper.device.config: # replace with the actual / proposed module FQCN
      log: boolean
      register: result

Inventory File (sanitized)

[junos]
device1 ansible_host= ansible_user=jcluser ansible_ssh_pass=<*******>
 
[junos:vars]
ansible_connection=ansible.netcommon.netconf
ansible_network_os=juniper.device.junos
 
 
---
 
## Steps to Trigger the Current Limitation
 
1. Need to manually generate the junos cli command and push it explicitly on device
2.  junos cli command required :
 
set firewall family inet filter <filtername> term <termname> then log
 
 
3.
 
---
 
## Expected Behavior (with the new feature)
 
if log: true
set firewall family inet filter <filtername> term <termname> then log
 
 
## Current Behavior (without the feature)
 
currently we dont have 'log' attribute supported in juniper.device.junos_acls module
 
 
---
 
## Alternatives Considered
 
this can be handled using j2 templates for rendering the junos cli , but since customer requirement is to fully utilize the junos ansible module for achieving this functionality
 
---
 
## Junos Platform / RPC Details (if applicable)
 
| Field | Value |
|-------|-------|
| Platform(s) | MX, QFX, EX, SRX, vMX, cRPD |
| Junos version(s) | 18.1R3 + Junos Evolved |
| Relevant RPC / CLI command |  |
 
set firewall family inet filter <filtername> term <termname> then log
 
---
 
## Environment
 
| Item | Version |
|------|---------|
| Collection namespace & version | <!-- e.g. juniper.device 3.1.0 --> |
| ansible-core | 2.17.14 |
| Python | 3.11.13 |
| OS | Linux |
| junos-eznc | 2.8.2 |
| ncclient | 0.7.0 |
 
---
 
## Additional Context
 
<!-- Any other context, references, prior art, or screenshots about the feature request. -->
 
---
 
## Support
 
As Red Hat Ansible Certified Content, this collection is entitled to support through the **Ansible Automation Platform (AAP)** using the **Create issue** button on the top right corner of the [AAP support portal](https://access.redhat.com/support/cases/#/case/new).
 
If a support case cannot be opened with Red Hat and the collection has been obtained either from Galaxy or GitHub, there may be community help available on the [Ansible Forum](https://forum.ansible.com/).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions