36 lines
904 B
YAML
36 lines
904 B
YAML
- name: Update nginx stream configuration
|
|
hosts: colors:kubernetes
|
|
become: true
|
|
become_user: root
|
|
become_method: sudo
|
|
vars_files:
|
|
- vars.yaml
|
|
tasks:
|
|
- name: Ensure curl, unzip installed
|
|
ansible.builtin.dnf:
|
|
name:
|
|
- curl
|
|
- unzip
|
|
state: present
|
|
- name: Download aws cli zip
|
|
ansible.builtin.get_url:
|
|
url: https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip
|
|
dest: /tmp/awscliv2.zip
|
|
mode: '0600'
|
|
- name: Remove /tmp/aws before unzipping
|
|
file:
|
|
path: /tmp/aws
|
|
state: absent
|
|
- name: Unzip aws cli
|
|
ansible.builtin.unarchive:
|
|
src: /tmp/awscliv2.zip
|
|
dest: /tmp
|
|
remote_src: yes
|
|
- name: Run aws installer
|
|
ansible.builtin.shell: /tmp/aws/install
|
|
register: result
|
|
ignore_errors: true
|
|
- name: Run aws updater
|
|
ansible.builtin.shell: /tmp/aws/install -u
|
|
when: result is failed
|