Merge "Ansible lint: use command module instead of shell"

This commit is contained in:
Zuul 2020-01-14 10:31:30 +00:00 committed by Gerrit Code Review
commit a4e7a13ac7
3 changed files with 3 additions and 3 deletions

View File

@ -47,7 +47,7 @@
- name: Copying MariaDB log file to /tmp - name: Copying MariaDB log file to /tmp
become: true become: true
shell: "docker cp {{ mariadb_service.container_name }}:/var/log/kolla/mariadb/mariadb.log /tmp/mariadb_tmp.log" command: "docker cp {{ mariadb_service.container_name }}:/var/log/kolla/mariadb/mariadb.log /tmp/mariadb_tmp.log"
# Look for sequence number in logs. Format is: # Look for sequence number in logs. Format is:
# WSREP: Recovered position: <UUID>:<seqno>. # WSREP: Recovered position: <UUID>:<seqno>.

View File

@ -12,7 +12,7 @@
# NOTE(duonghq): it's only a basic check, should be refined later # NOTE(duonghq): it's only a basic check, should be refined later
- name: Check if ansible user can do passwordless sudo - name: Check if ansible user can do passwordless sudo
shell: "true" command: "true"
become: yes become: yes
register: result register: result
failed_when: result is failed failed_when: result is failed

View File

@ -23,7 +23,7 @@
service_name: "rabbitmq" service_name: "rabbitmq"
service: "{{ rabbitmq_services[service_name] }}" service: "{{ rabbitmq_services[service_name] }}"
become: true become: true
shell: "docker exec {{ service.container_name }} rabbitmqctl wait {{ rabbitmq_pid_file }}" command: "docker exec {{ service.container_name }} rabbitmqctl wait {{ rabbitmq_pid_file }}"
when: when:
- inventory_hostname == groups[service.group]|first - inventory_hostname == groups[service.group]|first