Skip to content

Commit 42a1595

Browse files
ekohlehelms
authored andcommitted
Ansible lint cleanups
1 parent 6a10da1 commit 42a1595

File tree

9 files changed

+23
-22
lines changed

9 files changed

+23
-22
lines changed

playbooks/runcible.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@
3636
become: true
3737

3838
- name: "Install RVM gpg key"
39-
shell: "gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3"
39+
command: "gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3"
4040

4141
- name: "Install RVM"
42-
shell: "curl -sSL https://get.rvm.io | bash -s stable --ruby"
42+
command: "curl -sSL https://get.rvm.io | bash -s stable --ruby"
4343

4444
- name: "Install librarian-puppet"
4545
gem:
@@ -57,7 +57,7 @@
5757
dest: "/home/vagrant/puppet-pulp/Puppetfile"
5858

5959
- name: "Install Puppet modules"
60-
shell: "/home/vagrant/bin/librarian-puppet install"
60+
command: "/home/vagrant/bin/librarian-puppet install"
6161
args:
6262
chdir: "/home/vagrant/puppet-pulp"
6363
remote_user: "vagrant"
@@ -83,7 +83,7 @@
8383

8484
- name: "Run puppet apply"
8585
become: true
86-
shell: "/opt/puppetlabs/bin/puppet apply --modulepath=/home/vagrant/puppet-pulp/modules /home/vagrant/test.pp"
86+
command: "/opt/puppetlabs/bin/puppet apply --modulepath=/home/vagrant/puppet-pulp/modules /home/vagrant/test.pp"
8787

8888
- name: "Open up permissions on server.conf"
8989
become: true
@@ -106,6 +106,6 @@
106106
chdir: "/home/vagrant/runcible"
107107

108108
- name: "Run tests"
109-
shell: "rake test mode=all"
109+
command: "rake test mode=all"
110110
args:
111111
chdir: "/home/vagrant/runcible"

roles/fips/tasks/main.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
- name: 'Install dracut-fips'
3-
package:
3+
package:
44
name: dracut-fips
55
state: present
66

@@ -21,7 +21,7 @@
2121
ignore_errors: true
2222

2323
- name: Waiting for reboot
24-
local_action: wait_for
24+
local_action: wait_for
2525
host={{ ansible_ssh_host }}
2626
state=started
2727

roles/plugins/foreman_openscap/seed/tasks/main.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
---
22
- name: 'Import puppet classes'
3-
shell: >
3+
command: >
44
{{ foreman_openscap_hammer }} proxy import-classes --name {{ foreman_openscap_proxy_name }}
5-
when: '{{ foreman_openscap_proxy_name != False }}'
5+
when: foreman_openscap_proxy_name != False
66

77
- name: 'Import default scap content'
8-
shell: >
8+
command: >
99
foreman-rake foreman_openscap:bulk_upload:default
10-
when: '{{ foreman_openscap_proxy_name != False }}'
10+
when: foreman_openscap_proxy_name != False
1111

1212
# TODO: disabled until cli is fixed
1313
# - name: 'Create example policy'

roles/pulp_repositories/tasks/main.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
- name: Add Pulp {{ pulp_repositories_version }} stable repository
2+
- name: "Add Pulp {{ pulp_repositories_version }} stable repository"
33
yum_repository:
44
name: pulp-repository
55
description: Pulp release repository
@@ -23,6 +23,6 @@
2323
yum_repository:
2424
name: jortel-gofer
2525
description: Copr repo for gofer owned by jortel
26-
baseurl: https://copr-be.cloud.fedoraproject.org/results/jortel/gofer/epel-{{ ansible_distribution_major_version }}-x86_64/
26+
baseurl: "https://copr-be.cloud.fedoraproject.org/results/jortel/gofer/epel-{{ ansible_distribution_major_version }}-x86_64/"
2727
gpgcheck: 1
2828
gpgkey: https://copr-be.cloud.fedoraproject.org/results/jortel/gofer/pubkey.gpg

roles/puppet_repositories/tasks/puppetlabs-5-debian.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
- name: 'Install Puppet 5 repository'
77
apt_repository:
8-
repo: deb http://apt.puppet.com {{ ansible_distribution_release }} puppet5
8+
repo: "deb http://apt.puppet.com {{ ansible_distribution_release }} puppet5"
99
state: present
1010

1111
- name: 'Install backports'
@@ -17,5 +17,5 @@
1717
apt:
1818
name: 'openjdk-8-jre-headless'
1919
state: present
20-
default_release: "{{ansible_distribution_release}}-backports"
20+
default_release: "{{ ansible_distribution_release }}-backports"
2121
when: ansible_distribution_release == "jessie"

roles/puppet_repositories/tasks/puppetlabs-nightly-debian.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,5 @@
2525
apt:
2626
name: 'openjdk-8-jre-headless'
2727
state: present
28-
default_release: "{{ansible_distribution_release}}-backports"
28+
default_release: "{{ ansible_distribution_release }}-backports"
2929
when: ansible_distribution_release == "jessie"
+4-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
- name: "Create alias for testing command"
2-
lineinfile:
3-
dest: ~/.bash_profile
2+
lineinfile:
3+
dest: ~/.bash_profile
44
line: "alias {{ pytest_project_alias }}=\"{{ pytest_project_command }}\""
5-
when: pytest_project_alias != ""
5+
when: pytest_project_alias
66

77
- debug:
88
msg: |
@@ -11,4 +11,4 @@
1111
1212
- debug:
1313
msg: "The testing command is aliased as {{ pytest_project_alias }}"
14-
when: pytest_project_alias != ""
14+
when: pytest_project_alias

roles/robottelo/tasks/main.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
- include_tasks: ssh.yml
1515

1616
- name: robottelo properties file
17-
shell: cp robottelo.properties.sample robottelo.properties
17+
command: cp robottelo.properties.sample robottelo.properties
1818
args:
1919
chdir: "{{ robottelo_directory }}"
2020

roles/unpriviledged_user/tasks/main.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@
2424
mode: 0700
2525
become: true
2626

27-
- lineinfile:
27+
- name: "Ensure public key is in authorized_keys"
28+
lineinfile:
2829
line: "{{ lookup('file', unpriviledged_user_import_ssh_pub_key) }}"
2930
path: "/home/{{ unpriviledged_user_username }}/.ssh/authorized_keys"
3031
create: yes

0 commit comments

Comments
 (0)