22 lines
499 B
YAML
22 lines
499 B
YAML
---
|
|
- name: install git packages
|
|
package:
|
|
name: "{{ git_packages }}"
|
|
state: present
|
|
|
|
- name: ensure git directory is present
|
|
file:
|
|
path: /home/admin/clones
|
|
state: directory
|
|
mode: 0755
|
|
owner: admin
|
|
group: admin
|
|
|
|
- name: clone git repositories
|
|
git:
|
|
repo: "{{ item.value.repo_url }}"
|
|
dest: "/home/admin/clones/{{ item.key }}"
|
|
version: "{{ item.value.version }}"
|
|
force: "{{ item.value.force }}"
|
|
loop: "{{ common_repos | dict2items }}"
|
|
become: false
|