darkwizard242.atom

:warning::rotating_light: 此项目已不再维护,并已归档。

Ansible 角色:atom

该角色用于在 UbuntuCentOS 系统上安装(默认为) atom 软件包,或在以变量传递的情况下卸载它。

需求

无。

角色变量

可用的变量列表如下(位于 defaults/main.yml):

变量列表:

atom_app: atom
atom_desired_state: present
atom_gpg_key: https://packagecloud.io/AtomEditor/atom/gpgkey
atom_repo_desired_state: present
atom_repo_debian: deb [arch=amd64] https://packagecloud.io/AtomEditor/atom/any/ any main
atom_repo_debian_filename: atom
atom_repo_el: https://packagecloud.io/AtomEditor/atom/el/7/$basearch
atom_repo_el_name: Atom
atom_repo_el_description: Atom 编辑器
atom_repo_el_gpgcheck: no
atom_repo_el_repogpgcheck: yes
atom_repo_el_enabled: yes
atom_repo_el_filename: atom

变量表:

变量 描述
atom_app 定义要安装的应用,如 atom
atom_desired_state 动态设置是否安装(即 presentlatest)或卸载(即 absent)该软件包。默认为 present
atom_gpg_key Atom 的 GPG 密钥
atom_repo_desired_state 用于下载 Atom 的存储库状态。可以是 'present' 或 'absent'。
atom_repo_debian 针对基于 Debian 系统的 Atom 存储库链接。
atom_repo_debian_filename 保存 Atom 存储库的文件名,位于 /etc/apt/sources.list.d/
atom_repo_el 针对 EL 系统的 Atom 存储库链接。
atom_repo_el_name EL 系统的 Atom 存储库名称。
atom_repo_el_description EL 系统 Atom 存储库的描述。
atom_repo_el_gpgcheck 对 GPG 密钥进行 GPG 检查的布尔操作。可以是 yesno
atom_repo_el_repogpgcheck 对 Atom 存储库进行 GPG 检查的布尔操作。可以是 yesno
atom_repo_el_enabled 设置存储库为启用或禁用的布尔操作。可以是 yesno
atom_repo_el_filename 保存 Atom 存储库的文件名,位于 /etc/yum.repos.d/

依赖

示例剧本

在 Ansible 剧本中,使用角色的默认行为(即安装 atom 软件包)。

- hosts: servers
  roles:
    - darkwizard242.atom

在 Ansible 剧本中,自定义角色的行为(即安装最新的 atom 软件包)。

- hosts: servers
  roles:
    - darkwizard242.atom
  vars:
    atom_desired_state: latest

在 Ansible 剧本中,自定义角色的行为(即卸载 atom 软件包)。

- hosts: servers
  roles:
    - darkwizard242.atom
  vars:
    atom_desired_state: absent

许可证

MIT

作者信息

该角色由 Ali Muhammad 创建。

关于项目

Atom editor ansible role for installation/uninstallation.

安装
ansible-galaxy install darkwizard242.atom
许可证
mit
下载
5.9k
拥有者
Senior DevOps/CloudOps Engineer. Dedicated to Automating everything I come across. Love to work on and learn new technologies/tools everyday!