Update yum.py (#67252)

Move the simpler name list example to the top of EXAMPLES.
Those with v2.11 loop deprecation warnings will be looking for a solution.
This commit is contained in:
Matt Warren 2020-02-11 14:03:28 -05:00 committed by GitHub
parent 7e83c40957
commit a8a89b7102
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -246,7 +246,15 @@ EXAMPLES = '''
name: httpd
state: latest
- name: ensure a list of packages installed
- name: install a list of packages (suitable replacement for 2.11 loop deprecation warning)
yum:
name:
- nginx
- postgresql
- postgresql-server
state: present
- name: install a list of packages with a list variable
yum:
name: "{{ packages }}"
vars:
@ -316,14 +324,6 @@ EXAMPLES = '''
name: sos
disablerepo: "epel,ol7_latest"
- name: Install a list of packages
yum:
name:
- nginx
- postgresql
- postgresql-server
state: present
- name: Download the nginx package but do not install it
yum:
name: