mirror of
https://github.com/roles-ansible/ansible_role_base.git
synced 2024-08-16 14:29:50 +02:00
26 lines
622 B
YAML
26 lines
622 B
YAML
---
|
|
- name: Update apt cache
|
|
become: true
|
|
ansible.builtin.apt:
|
|
cache_valid_time: 3600
|
|
update_cache: true
|
|
when:
|
|
- ansible_pkg_mgr == "apt"
|
|
|
|
- name: Install keychain to support ssh agent
|
|
become: true
|
|
ansible.builtin.package:
|
|
name: keychain
|
|
state: "{{ base__package_state }}"
|
|
when:
|
|
- ansible_os_family != 'RedHat'
|
|
|
|
- name: Install keychain on centos
|
|
become: true
|
|
ansible.builtin.yum:
|
|
name:
|
|
- "{{ _base__keychain_rpm }}"
|
|
- libselinux-python
|
|
state: "{{ base__package_state }}"
|
|
when:
|
|
- ansible_os_family == 'RedHat' and ansible_distribution_version | float <= 7
|