Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Support for startup config in exos_config & exos_facts #512

Open
ng-bsy opened this issue Jan 4, 2023 · 3 comments
Open

Feature: Support for startup config in exos_config & exos_facts #512

ng-bsy opened this issue Jan 4, 2023 · 3 comments
Labels
waiting_on_contributor Needs help. Feel free to engage to get things unblocked

Comments

@ng-bsy
Copy link

ng-bsy commented Jan 4, 2023

SUMMARY

To my understanding, exos_config and exos_facts only represent and let you manipulate or make backups of the current active (running) config.
For my use case I'd like to see the same possibilities for the saved (startup) config.
E.g.

  • Make a backup of the current startup config via exos_config
  • Get current startup config via exos_facts
ISSUE TYPE
  • Feature Idea
COMPONENT NAME
  • exos_config
  • exos_facts
ADDITIONAL INFORMATION
# use of exos_facts
- community.network.exos_facts:
    gather_subset: config
  register: exos_facts
- ansible.builtin.debug:
    msg:
      - "{{ exos_facts.ansible_facts.ansible_net_config_startup }}"
      - "{{ exos_facts.ansible_facts.ansible_net_config_active }}"

# use of exos_config
- community.network.exos_config:
    backup: yes
    backup_options:
      filename: backup_startup.cfg
      dir_path: /home/user
    config: startup
      

Thanks a lot

@ng-bsy ng-bsy changed the title Support for startup config in exos_config & exos_facts Feature: Support for startup config in exos_config & exos_facts Jan 4, 2023
@Andersson007
Copy link
Contributor

@ng-bsy hello, thanks for reporting the issue!

cc (team_extreme) @LindsayHill @ujwalkomarla

in case someone new wants to pick it up, there's the Quick start dev guide

@Andersson007 Andersson007 added the waiting_on_contributor Needs help. Feel free to engage to get things unblocked label Jan 6, 2023
@ng-bsy
Copy link
Author

ng-bsy commented Jan 9, 2023

For now I found a way, using netcommon, to do a manual backup of the startup config, but nontheless would it be nice to have the official modules support it:

- ansible.netcommon.net_get:
    src: nms.xsf
    dest: "{{ /home/user/startup_config"

@Andersson007
Copy link
Contributor

@ng-bsy the task you posted looks like it has a simple interface, hasn't it?
Maybe rather than writing a new piece of code someone needs to maintain, would it be good just to put info about your solutions in related modules, e.g. in DOCUMENTATION and EXAMPLES sections?
Something like:

- name: Backup the startup config
  ansible.netcommon.net_get:
    src: nms.xsf
    dest: /home/user/startup_config

what do you think? If you're OK with it, would you like to do it using the Quick-start guide?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting_on_contributor Needs help. Feel free to engage to get things unblocked
Projects
None yet
Development

No branches or pull requests

2 participants