Commit 0a893593 by John Jarvis

fixing with_* syntax to avoid 1.4 warnings

parent af126ae9
...@@ -8,12 +8,12 @@ ...@@ -8,12 +8,12 @@
- name: download browser debian packages from S3 - name: download browser debian packages from S3
get_url: dest="/tmp/{{ item.name }}" url="{{ item.url }}" get_url: dest="/tmp/{{ item.name }}" url="{{ item.url }}"
register: download_deb register: download_deb
with_items: "{{ browser_s3_deb_pkgs }}" with_items: browser_s3_deb_pkgs
- name: install browser debian packages - name: install browser debian packages
shell: gdebi -nq /tmp/{{ item.name }} shell: gdebi -nq /tmp/{{ item.name }}
when: download_deb.changed when: download_deb.changed
with_items: "{{ browser_s3_deb_pkgs }}" with_items: browser_s3_deb_pkgs
- name: Install ChromeDriver - name: Install ChromeDriver
get_url: get_url:
......
...@@ -2,10 +2,10 @@ ...@@ -2,10 +2,10 @@
- name: forum | test that the required service are listening - name: forum | test that the required service are listening
wait_for: port={{ item.port }} host={{ item.host }} timeout=30 wait_for: port={{ item.port }} host={{ item.host }} timeout=30
with_items: "{{ forum_services }}" with_items: forum_services
when: not devstack when: not devstack
- name: forum | test that mongo replica set members are listing - name: forum | test that mongo replica set members are listing
wait_for: port={{ FORUM_MONGO_PORT }} host={{ item }} timeout=30 wait_for: port={{ FORUM_MONGO_PORT }} host={{ item }} timeout=30
with_items: "{{ FORUM_MONGO_HOSTS }}" with_items: FORUM_MONGO_HOSTS
when: not devstack when: not devstack
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
# Dependencies: # Dependencies:
# - common # - common
# - nginx # - nginx
# #
# Example play: # Example play:
# roles: # roles:
# - common # - common
...@@ -60,16 +60,16 @@ ...@@ -60,16 +60,16 @@
- name: copying sync scripts - name: copying sync scripts
copy: src={{ item }} dest={{ gh_mirror_app_dir }}/{{ item }} copy: src={{ item }} dest={{ gh_mirror_app_dir }}/{{ item }}
with_items: "{{ gh_mirror_app_files }}" with_items: gh_mirror_app_files
- name: creating cron job to update repos - name: creating cron job to update repos
cron: cron:
name: "update repos from github" name: "update repos from github"
job: "/usr/bin/python {{ gh_mirror_app_dir }}/repos_from_orgs.py -d {{ gh_mirror_data_dir }}" job: "/usr/bin/python {{ gh_mirror_app_dir }}/repos_from_orgs.py -d {{ gh_mirror_data_dir }}"
- name: creating cron to update github repo list - name: creating cron to update github repo list
cron: cron:
name: "refresh repo list from github" name: "refresh repo list from github"
job: "/usr/bin/python {{ gh_mirror_app_dir}}/repos_from_orgs.py -r" job: "/usr/bin/python {{ gh_mirror_app_dir}}/repos_from_orgs.py -r"
minute: 0 minute: 0
...@@ -61,16 +61,16 @@ ...@@ -61,16 +61,16 @@
- name: download Jenkins plugins - name: download Jenkins plugins
get_url: url=http://updates.jenkins-ci.org/download/plugins/{{ item.name }}/{{ item.version }}/{{ item.name }}.hpi get_url: url=http://updates.jenkins-ci.org/download/plugins/{{ item.name }}/{{ item.version }}/{{ item.name }}.hpi
dest=/tmp/{{ item.name }}_{{ item.version }} dest=/tmp/{{ item.name }}_{{ item.version }}
with_items: "{{ jenkins_plugins }}" with_items: jenkins_plugins
- name: install Jenkins plugins - name: install Jenkins plugins
command: cp /tmp/{{ item.name }}_{{ item.version }} {{ jenkins_home }}/plugins/{{ item.name }}.hpi command: cp /tmp/{{ item.name }}_{{ item.version }} {{ jenkins_home }}/plugins/{{ item.name }}.hpi
with_items: "{{ jenkins_plugins }}" with_items: jenkins_plugins
- name: set Jenkins plugin permissions - name: set Jenkins plugin permissions
file: path={{ jenkins_home }}/plugins/{{ item.name }}.hpi file: path={{ jenkins_home }}/plugins/{{ item.name }}.hpi
owner={{ jenkins_user }} group={{ jenkins_group }} mode=700 owner={{ jenkins_user }} group={{ jenkins_group }} mode=700
with_items: "{{ jenkins_plugins }}" with_items: jenkins_plugins
notify: notify:
- jenkins_master | restart Jenkins - jenkins_master | restart Jenkins
...@@ -80,23 +80,23 @@ ...@@ -80,23 +80,23 @@
# Until then, we compile and install the forks ourselves. # Until then, we compile and install the forks ourselves.
- name: checkout custom plugin repo - name: checkout custom plugin repo
git: repo={{ item.repo_url }} dest=/tmp/{{ item.repo_name }} version={{ item.version }} git: repo={{ item.repo_url }} dest=/tmp/{{ item.repo_name }} version={{ item.version }}
with_items: "{{ jenkins_custom_plugins }}" with_items: jenkins_custom_plugins
- name: compile custom plugins - name: compile custom plugins
command: mvn -Dmaven.test.skip=true install chdir=/tmp/{{ item.repo_name }} command: mvn -Dmaven.test.skip=true install chdir=/tmp/{{ item.repo_name }}
with_items: "{{ jenkins_custom_plugins }}" with_items: jenkins_custom_plugins
- name: install custom plugins - name: install custom plugins
command: mv /tmp/{{ item.repo_name }}/target/{{ item.package }} command: mv /tmp/{{ item.repo_name }}/target/{{ item.package }}
{{ jenkins_home }}/plugins/{{ item.package }} {{ jenkins_home }}/plugins/{{ item.package }}
with_items: "{{ jenkins_custom_plugins }}" with_items: jenkins_custom_plugins
notify: notify:
- jenkins_master | restart Jenkins - jenkins_master | restart Jenkins
- name: set custom plugin permissions - name: set custom plugin permissions
file: path={{ jenkins_home }}/plugins/{{ item.package }} file: path={{ jenkins_home }}/plugins/{{ item.package }}
owner={{ jenkins_user }} group={{ jenkins_group }} mode=700 owner={{ jenkins_user }} group={{ jenkins_group }} mode=700
with_items: "{{ jenkins_custom_plugins }}" with_items: jenkins_custom_plugins
# Plugins that are bundled with Jenkins are "pinned". # Plugins that are bundled with Jenkins are "pinned".
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
- name: create plugin pin files - name: create plugin pin files
command: touch {{ jenkins_home }}/plugins/{{ item }}.jpi.pinned command: touch {{ jenkins_home }}/plugins/{{ item }}.jpi.pinned
creates={{ jenkins_home }}/plugins/{{ item }}.jpi.pinned creates={{ jenkins_home }}/plugins/{{ item }}.jpi.pinned
with_items: "{{ jenkins_bundled_plugins }}" with_items: jenkins_bundled_plugins
- name: setup nginix vhost - name: setup nginix vhost
template: template:
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
{{ jenkins_pip }} install --use-wheel --no-index --find-links={{ jenkins_wheel_dir }} \"${item.pkg}\" {{ jenkins_pip }} install --use-wheel --no-index --find-links={{ jenkins_wheel_dir }} \"${item.pkg}\"
creates={{ jenkins_wheel_dir }}/${item.wheel}" creates={{ jenkins_wheel_dir }}/${item.wheel}"
sudo_user: "{{ jenkins_user }}" sudo_user: "{{ jenkins_user }}"
with_items: "{{ jenkins_wheels }}" with_items: jenkins_wheels
- name: jenkins_worker | Add wheel_venv.sh script - name: jenkins_worker | Add wheel_venv.sh script
template: template:
......
...@@ -59,7 +59,7 @@ ...@@ -59,7 +59,7 @@
ttl: 300 ttl: 300
record: "{{ dns_name }}.{{ dns_zone }}" record: "{{ dns_name }}.{{ dns_zone }}"
value: "{{ item.public_dns_name }}" value: "{{ item.public_dns_name }}"
with_items: "{{ ec2.instances }}" with_items: ec2.instances
- name: Add DNS name studio - name: Add DNS name studio
local_action: local_action:
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
ttl: 300 ttl: 300
record: "studio.{{ dns_name }}.{{ dns_zone }}" record: "studio.{{ dns_name }}.{{ dns_zone }}"
value: "{{ item.public_dns_name }}" value: "{{ item.public_dns_name }}"
with_items: "{{ ec2.instances }}" with_items: ec2.instances
- name: Add DNS name preview - name: Add DNS name preview
local_action: local_action:
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
ttl: 300 ttl: 300
record: "preview.{{ dns_name }}.{{ dns_zone }}" record: "preview.{{ dns_name }}.{{ dns_zone }}"
value: "{{ item.public_dns_name }}" value: "{{ item.public_dns_name }}"
with_items: "{{ ec2.instances }}" with_items: ec2.instances
- name: Add new instance to host group - name: Add new instance to host group
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
add_host add_host
hostname={{ item.public_ip }} hostname={{ item.public_ip }}
groupname=launched groupname=launched
with_items: "{{ ec2.instances }}" with_items: ec2.instances
- name: Wait for SSH to come up - name: Wait for SSH to come up
local_action: > local_action: >
...@@ -101,4 +101,4 @@ ...@@ -101,4 +101,4 @@
port=22 port=22
delay=60 delay=60
timeout=320 timeout=320
with_items: "{{ ec2.instances }}" with_items: ec2.instances
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
- name: set login shell for app accounts - name: set login shell for app accounts
user: name={{ item.user }} shell="/bin/bash" user: name={{ item.user }} shell="/bin/bash"
with_items: "{{ localdev_accounts }}" with_items: localdev_accounts
# Ensure forum user has permissions to access .gem and .rbenv # Ensure forum user has permissions to access .gem and .rbenv
# This is a little twisty: the forum role sets the owner and group to www-data # This is a little twisty: the forum role sets the owner and group to www-data
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
template: template:
src=app_bashrc.j2 dest={{ item.home }}/.bashrc src=app_bashrc.j2 dest={{ item.home }}/.bashrc
owner={{ item.user }} mode=755 owner={{ item.user }} mode=755
with_items: "{{ localdev_accounts }}" with_items: localdev_accounts
# Default to the correct git config # Default to the correct git config
# No more accidentally force pushing to master! :) # No more accidentally force pushing to master! :)
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
copy: copy:
src=gitconfig dest={{ item.home }}/.gitconfig src=gitconfig dest={{ item.home }}/.gitconfig
owner={{ item.user }} mode=700 owner={{ item.user }} mode=700
with_items: "{{ localdev_accounts }}" with_items: localdev_accounts
# Configure X11 for application users # Configure X11 for application users
- name: preserve DISPLAY for sudo - name: preserve DISPLAY for sudo
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
# license: https://github.com/edx/configuration/blob/master/LICENSE.TXT # license: https://github.com/edx/configuration/blob/master/LICENSE.TXT
# #
# Tasks for role s3fs # Tasks for role s3fs
# #
# Overview: # Overview:
# #
# Installs s3fs, but doesn't mount any buckets. # Installs s3fs, but doesn't mount any buckets.
...@@ -29,14 +29,14 @@ ...@@ -29,14 +29,14 @@
# file: # file:
# path={{ item.mount_point }} owner={{ item.owner }} # path={{ item.mount_point }} owner={{ item.owner }}
# group={{ item.group }} mode={{ item.mode }} state="directory" # group={{ item.group }} mode={{ item.mode }} state="directory"
# with_items: "{{ my_role_s3fs_mounts }}" # with_items: my_role_s3fs_mounts
# #
# - name: my_role | mount s3 buckets # - name: my_role | mount s3 buckets
# mount: # mount:
# name={{ item.mount_point }} src={{ item.bucket }} fstype=fuse.s3fs # name={{ item.mount_point }} src={{ item.bucket }} fstype=fuse.s3fs
# opts=use_cache=/tmp,iam_role={{ task_iam_role }},allow_other state=mounted # opts=use_cache=/tmp,iam_role={{ task_iam_role }},allow_other state=mounted
# with_items: "{{ myrole_s3fs_mounts }}" # with_items: myrole_s3fs_mounts
# #
# Example play: # Example play:
# #
# Required sudo for the installation phase. # Required sudo for the installation phase.
...@@ -64,19 +64,19 @@ ...@@ -64,19 +64,19 @@
get_url: get_url:
url={{ s3fs_download_url }} url={{ s3fs_download_url }}
dest={{ s3fs_temp_dir }} dest={{ s3fs_temp_dir }}
- name: extract package - name: extract package
shell: shell:
/bin/tar -xzf {{ s3fs_archive }} /bin/tar -xzf {{ s3fs_archive }}
chdir={{ s3fs_temp_dir }} chdir={{ s3fs_temp_dir }}
creates={{ s3fs_temp_dir }}/{{ s3fs_version }}/configure creates={{ s3fs_temp_dir }}/{{ s3fs_version }}/configure
- name: configure - name: configure
shell: shell:
./configure ./configure
chdir={{ s3fs_temp_dir }}/{{ s3fs_version }} chdir={{ s3fs_temp_dir }}/{{ s3fs_version }}
creates={{ s3fs_temp_dir }}/{{ s3fs_version }}/config.status creates={{ s3fs_temp_dir }}/{{ s3fs_version }}/config.status
- name: make - name: make
shell: shell:
/usr/bin/make /usr/bin/make
...@@ -87,4 +87,4 @@ ...@@ -87,4 +87,4 @@
shell: shell:
/usr/bin/make install /usr/bin/make install
chdir={{ s3fs_temp_dir }}/{{ s3fs_version }} chdir={{ s3fs_temp_dir }}/{{ s3fs_version }}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment