Commit 0a893593 by John Jarvis

fixing with_* syntax to avoid 1.4 warnings

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