Skip to content

[FEATURE]: Add groups to runtime.yml to define a group for all modules (to use in module_defaults) #206

@hrtmhood

Description

@hrtmhood

Describe the solution you'd like
Currently every module declaration needs many parameters specifying
e.g.

- name: Configure NTP settings
  dellemc.powerscale.settings:
    onefs_host: "{{ onefs_host }}"
    port_no: "{{ onefs_port }}"
    verify_ssl: "{{ onefs_ssl }}"
    api_user: "{{ onefs_user }}"
    api_password: "{{ onefs_password }}"
    ntp_servers: "{{ ntp_servers }}"

This is cumbersome and requires a lot of boilerplate for each module in the playbook.

The module_defaults declaration allows specifying default parameter values for all invocations of a module, OR, a module action group
e.g.

- hosts: localhost
  module_defaults:
    group/dellemc.powerscale.all:
      option_name: option_value

Therefore please define a group for all modules in the collection in runtime.yml to enable this:
e.g.

action_groups:
  all:
    - accesszone
    - ads
    - ...
    - writeable_snapshots

Describe alternatives you've considered
The group could be defined in our playbook but it would require updating whenever new modules are added to the collection which requires user action

Additional context
See:
https://docs.ansible.com/ansible/latest/playbook_guide/playbooks_module_defaults.html
https://docs.ansible.com/ansible/latest/dev_guide/developing_collections_structure.html#meta-runtime-yml

Metadata

Metadata

Labels

type/feature-requestThis is the default label associated with a feature request issue.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions