base_role/tasks/ansible.yml

37 lines
1012 B
YAML
Raw Normal View History

2024-01-06 01:38:28 +00:00
# -*- mode: yaml; indent-tabs-mode: nil; tab-width: 2; coding: utf-8-unix -*-
---
- name: "DEBUG: base ansible.yml ansible_distribution ansible_virtualization_role"
debug:
verbosity: 1
msg: "DEBUG: Including base ansible.yml {{ansible_distribution }} {{ ansible_virtualization_role|replace('NA', 'host') }}"
- set_fact:
BASE_SRC_ANSIBLE: "{{playbook_dir}}"
- block:
- name: Assemble from fragments from a directory
assemble:
2024-01-09 15:39:19 +00:00
src: "{{USR_LOCAL}}/etc/ansible/ansible.cfg"
2024-01-06 01:38:28 +00:00
regexp: "cfg$"
dest: "{{BASE_SRC_ANSIBLE}}/ansible.cfg"
ignore_errors: true
when: false
delegate_to: localhost
- name: clean boostrap wheels.sh and pip.sh
shell: |
LELTS=3
[ -n "{{BOX_PYTHON2_MINOR}}" ] && LELTS="2 $LELTS"
for PYVER in $LELTS ; do
if [ -f {{ BASE_USR_LOCAL }}/bin/pip$PYVER.sh ] ; then
[ -e {{ BASE_USR_LOCAL }}/bin/python$PYVER.bash ] && \
rm -f {{ BASE_USR_LOCAL }}/bin/python$PYVER.bash
fi
done
exit 0