From 78150e78045f9660216a1462c6869db94f0bee9c Mon Sep 17 00:00:00 2001 From: Seth Vidal Date: Tue, 25 Jun 2013 18:31:36 +0000 Subject: [PATCH 1/3] - make the global update only run on first setup - make the ntp/date install faster --- tasks/cloud_setup_basic.yml | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/tasks/cloud_setup_basic.yml b/tasks/cloud_setup_basic.yml index 5f73e128a4..91d2792526 100644 --- a/tasks/cloud_setup_basic.yml +++ b/tasks/cloud_setup_basic.yml @@ -1,16 +1,21 @@ --- - name: update all - action: command yum -y update - tags: - - packages - -- name: ntpdate install - action: yum state=installed pkg=ntpdate + command: yum -y update creates=/etc/sysconfig/global-upate-applied + register: updated tags: - packages -- name: ntp install - action: yum state=installed pkg=ntp +- name: write out global file + copy: content="updated" dest=/etc/sysconfig/global-update-applied + when: updated is defined + tags: + - packages + +- name: ntp pkgs + action: yum state=installed pkg=$item + with_items: + - ntpdate + - ntp tags: - packages From f500f91330c615480e65e1c4c90511f62ab6f2d8 Mon Sep 17 00:00:00 2001 From: Seth Vidal Date: Tue, 25 Jun 2013 18:34:57 +0000 Subject: [PATCH 2/3] upate != update --- tasks/cloud_setup_basic.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasks/cloud_setup_basic.yml b/tasks/cloud_setup_basic.yml index 91d2792526..aab45a447f 100644 --- a/tasks/cloud_setup_basic.yml +++ b/tasks/cloud_setup_basic.yml @@ -1,6 +1,6 @@ --- - name: update all - command: yum -y update creates=/etc/sysconfig/global-upate-applied + command: yum -y update creates=/etc/sysconfig/global-update-applied register: updated tags: - packages From 0e37af52f5aad2b400130a9f8bbc41f0624fbbd9 Mon Sep 17 00:00:00 2001 From: Seth Vidal Date: Tue, 25 Jun 2013 18:35:42 +0000 Subject: [PATCH 3/3] make the name mean something --- tasks/cloud_setup_basic.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasks/cloud_setup_basic.yml b/tasks/cloud_setup_basic.yml index aab45a447f..eb1f6c0687 100644 --- a/tasks/cloud_setup_basic.yml +++ b/tasks/cloud_setup_basic.yml @@ -5,7 +5,7 @@ tags: - packages -- name: write out global file +- name: write out global-update-applied file if we updated copy: content="updated" dest=/etc/sysconfig/global-update-applied when: updated is defined tags: