fix playbook for jenkins-agent

This commit is contained in:
2022-09-01 10:37:32 +07:00
parent 6eb86580b9
commit bfa45b409c

View File

@@ -133,24 +133,24 @@
become_user: root become_user: root
ansible.builtin.file: ansible.builtin.file:
src: /usr/local/bin/python3.8 src: /usr/local/bin/python3.8
dest: /usr/local/bin/python3 dest: /usr/bin/python3
state: link state: link
- name: Create symbolic link pip3 - name: Create symbolic link pip3
become_user: root become_user: root
ansible.builtin.file: ansible.builtin.file:
src: /usr/local/bin/pip3.8 src: /usr/local/bin/pip3.8
dest: /usr/local/bin/pip3 dest: /usr/bin/pip3
state: link state: link
- name: Update pip - name: Update pip
become_user: root become_user: root
pip: pip:
executable: /usr/local/bin/pip3 executable: /usr/bin/pip3
name: pip name: pip
extra_args: --upgrade extra_args: --upgrade
- name: Install Ansible - name: Install Ansible
become_user: root become_user: root
pip: pip:
executable: /usr/local/bin/pip3 executable: /usr/bin/pip3
name: name:
- selinux - selinux
- ansible<3.0 - ansible<3.0
@@ -158,7 +158,7 @@
- name: Reinstall Selinux - name: Reinstall Selinux
become_user: root become_user: root
pip: pip:
executable: /usr/local/bin/pip3 executable: /usr/bin/pip3
name: name:
- selinux - selinux
state: forcereinstall state: forcereinstall
@@ -192,10 +192,18 @@
retries: 10 retries: 10
timeout: 10 timeout: 10
- name: Install pip molecule - name: Install pip molecule
become_user: root
ansible.builtin.pip: ansible.builtin.pip:
executable: /usr/local/bin/pip3 executable: /usr/bin/pip3
name: molecule name:
- name: ensure github.com is a known host - molecule==3.5.2
- molecule-docker
- yamllint
- ansible-lint
- name: Update ansible community.docker collection
ansible.builtin.shell:
cmd: ansible-galaxy collection install community.docker
- name: Ensure github.com is a known host
lineinfile: lineinfile:
dest: ~/.ssh/known_hosts dest: ~/.ssh/known_hosts
create: yes create: yes