2012-10-08 19:35:54 +00:00
|
|
|
---
|
|
|
|
- name: update all
|
2013-06-25 18:34:57 +00:00
|
|
|
command: yum -y update creates=/etc/sysconfig/global-update-applied
|
2013-06-25 18:31:36 +00:00
|
|
|
register: updated
|
2012-10-08 19:35:54 +00:00
|
|
|
tags:
|
|
|
|
- packages
|
2013-06-25 18:31:36 +00:00
|
|
|
|
2013-06-25 18:35:42 +00:00
|
|
|
- name: write out global-update-applied file if we updated
|
2013-06-25 18:31:36 +00:00
|
|
|
copy: content="updated" dest=/etc/sysconfig/global-update-applied
|
|
|
|
when: updated is defined
|
2012-10-08 19:35:54 +00:00
|
|
|
tags:
|
|
|
|
- packages
|
2013-06-25 18:31:36 +00:00
|
|
|
|
|
|
|
- name: ntp pkgs
|
|
|
|
action: yum state=installed pkg=$item
|
|
|
|
with_items:
|
|
|
|
- ntpdate
|
|
|
|
- ntp
|
2012-12-05 06:19:23 +00:00
|
|
|
tags:
|
|
|
|
- packages
|
|
|
|
|
|
|
|
- name: put step-tickers in place
|
|
|
|
action: copy src=$files/common/step-tickers dest=/etc/ntp/step-tickers
|
|
|
|
|
|
|
|
- name: enable the service
|
|
|
|
action: service name=ntpd state=running enabled=true
|
|
|
|
|
2012-10-22 17:47:45 +00:00
|
|
|
- name: edit hostname to be instance name - prefix hostbase var if it exists
|
|
|
|
action: shell hostname ${hostbase}`curl -s http://169.254.169.254/latest/meta-data/instance-id`
|
2012-10-08 19:35:54 +00:00
|
|
|
tags:
|
|
|
|
- config
|
2012-11-02 06:22:19 +00:00
|
|
|
|
|
|
|
- name: add ansible root key
|
2013-06-17 13:54:17 +00:00
|
|
|
action: authorized_key user=root key="{{ item }}"
|
|
|
|
with_file:
|
|
|
|
- ${files}/common/ansible-pub-key
|
2012-10-08 19:35:54 +00:00
|
|
|
tags:
|
|
|
|
- config
|
2012-11-02 06:22:19 +00:00
|
|
|
|
|
|
|
- name: add root keys for sysadmin-main and other allowed users
|
2013-06-17 13:54:17 +00:00
|
|
|
action: authorized_key user=root key="{{ item }}"
|
|
|
|
with_pipe:
|
2013-06-17 15:41:41 +00:00
|
|
|
- "${auth_keys_from_fas} @sysadmin-main ${root_auth_users}"
|
2012-10-26 17:31:32 +00:00
|
|
|
tags:
|
|
|
|
- config
|
2013-07-02 19:26:24 +00:00
|
|
|
ignore_errors: true
|
2012-11-02 06:22:19 +00:00
|
|
|
|
2012-10-19 20:17:20 +00:00
|
|
|
# note - kinda should be a handler - but handlers need args
|
|
|
|
- name: restorecon
|
|
|
|
action: command restorecon -R /root/.ssh
|
|
|
|
tags:
|
|
|
|
- config
|
|
|
|
|