Skip to content

Commit

Permalink
Ansible lint cleanups
Browse files Browse the repository at this point in the history
  • Loading branch information
ekohl committed Mar 12, 2020
1 parent 55ac06a commit 59032bd
Show file tree
Hide file tree
Showing 10 changed files with 23 additions and 23 deletions.
10 changes: 5 additions & 5 deletions playbooks/runcible.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@
become: true

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

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

- name: "Install librarian-puppet"
gem:
Expand All @@ -57,7 +57,7 @@
dest: "/home/vagrant/puppet-pulp/Puppetfile"

- name: "Install Puppet modules"
shell: "/home/vagrant/bin/librarian-puppet install"
command: "/home/vagrant/bin/librarian-puppet install"
args:
chdir: "/home/vagrant/puppet-pulp"
remote_user: "vagrant"
Expand All @@ -83,7 +83,7 @@

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

- name: "Open up permissions on server.conf"
become: true
Expand All @@ -106,6 +106,6 @@
chdir: "/home/vagrant/runcible"

- name: "Run tests"
shell: "rake test mode=all"
command: "rake test mode=all"
args:
chdir: "/home/vagrant/runcible"
1 change: 0 additions & 1 deletion roles/customize_home/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
local_action:
module: stat
path: "{{ playbook_dir | dirname }}/user_devel_env_files/"
become: no
register: custom_home

- name: Copy files to home directory
Expand Down
4 changes: 2 additions & 2 deletions roles/fips/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
- name: 'Install dracut-fips'
package:
package:
name: dracut-fips
state: present

Expand All @@ -21,7 +21,7 @@
ignore_errors: true

- name: Waiting for reboot
local_action: wait_for
local_action: wait_for
host={{ ansible_ssh_host }}
state=started

Expand Down
8 changes: 4 additions & 4 deletions roles/plugins/foreman_openscap/seed/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---
- name: 'Import puppet classes'
shell: >
command: >
{{ foreman_openscap_hammer }} proxy import-classes --name {{ foreman_openscap_proxy_name }}
when: '{{ foreman_openscap_proxy_name != False }}'
when: foreman_openscap_proxy_name != False

- name: 'Import default scap content'
shell: >
command: >
foreman-rake foreman_openscap:bulk_upload:default
when: '{{ foreman_openscap_proxy_name != False }}'
when: foreman_openscap_proxy_name != False

# TODO: disabled until cli is fixed
# - name: 'Create example policy'
Expand Down
4 changes: 2 additions & 2 deletions roles/pulp_repositories/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
- name: Add Pulp {{ pulp_repositories_version }} stable repository
- name: "Add Pulp {{ pulp_repositories_version }} stable repository"
yum_repository:
name: pulp-repository
description: Pulp release repository
Expand All @@ -23,6 +23,6 @@
yum_repository:
name: jortel-gofer
description: Copr repo for gofer owned by jortel
baseurl: https://copr-be.cloud.fedoraproject.org/results/jortel/gofer/epel-{{ ansible_distribution_major_version }}-x86_64/
baseurl: "https://copr-be.cloud.fedoraproject.org/results/jortel/gofer/epel-{{ ansible_distribution_major_version }}-x86_64/"
gpgcheck: 1
gpgkey: https://copr-be.cloud.fedoraproject.org/results/jortel/gofer/pubkey.gpg
4 changes: 2 additions & 2 deletions roles/puppet_repositories/tasks/puppetlabs-5-debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

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

- name: 'Install backports'
Expand All @@ -17,5 +17,5 @@
apt:
name: 'openjdk-8-jre-headless'
state: present
default_release: "{{ansible_distribution_release}}-backports"
default_release: "{{ ansible_distribution_release }}-backports"
when: ansible_distribution_release == "jessie"
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@
apt:
name: 'openjdk-8-jre-headless'
state: present
default_release: "{{ansible_distribution_release}}-backports"
default_release: "{{ ansible_distribution_release }}-backports"
when: ansible_distribution_release == "jessie"
8 changes: 4 additions & 4 deletions roles/pytest_project/tasks/local_env.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
- name: "Create alias for testing command"
lineinfile:
dest: ~/.bash_profile
lineinfile:
dest: ~/.bash_profile
line: "alias {{ pytest_project_alias }}=\"{{ pytest_project_command }}\""
when: pytest_project_alias != ""
when: pytest_project_alias

- debug:
msg: |
Expand All @@ -11,4 +11,4 @@
- debug:
msg: "The testing command is aliased as {{ pytest_project_alias }}"
when: pytest_project_alias != ""
when: pytest_project_alias
2 changes: 1 addition & 1 deletion roles/robottelo/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
- include_tasks: ssh.yml

- name: robottelo properties file
shell: cp robottelo.properties.sample robottelo.properties
command: cp robottelo.properties.sample robottelo.properties
args:
chdir: "{{ robottelo_directory }}"

Expand Down
3 changes: 2 additions & 1 deletion roles/unpriviledged_user/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@
mode: 0700
become: true

- lineinfile:
- name: "Ensure public key is in authorized_keys"
lineinfile:
line: "{{ lookup('file', unpriviledged_user_import_ssh_pub_key) }}"
path: "/home/{{ unpriviledged_user_username }}/.ssh/authorized_keys"
create: yes
Expand Down

0 comments on commit 59032bd

Please sign in to comment.