infOpen.git
git
安装 git 软件包。
需求
此角色需要 Ansible 2.8 或更高版本, 平台要求在元数据文件中列出。
测试
此角色使用 Molecule 进行测试。
本地和 GitHub Actions 测试默认在 Docker 上运行。 请参阅 molecule 文档以使用其他后端。
当前,测试在以下环境中进行:
- CentOS 7
- CentOS 8
- Debian Buster
- Debian Stretch
- Ubuntu Bionic
- Ubuntu Focal
并使用:
- Ansible 2.8.x
- Ansible 2.9.x
运行测试
使用 Docker 驱动
$ tox
您还可以使用环境变量配置 molecule 选项和命令:
MOLECULE_OPTIONS
默认: "--debug"MOLECULE_COMMAND
默认: "test"
$ MOLECULE_OPTIONS='' MOLECULE_COMMAND=converge tox
角色变量
默认角色变量
# 安装
git_packages: "{{ _git_packages }}"
git_repository_cache_valid_time: 3600
git_repository_update_cache: True
Debian 操作系统特定变量
_git_packages:
- name: 'git'
依赖
无
示例剧本
- hosts: servers
roles:
- { role: infOpen.git }
许可证
MIT
作者信息
Alexandre Chaussier(来自 Infopen 公司)
- https://www.infopen.pro
- a.chaussier [at] infopen.pro