All Projects → oVirt → Ovirt Ansible

oVirt / Ovirt Ansible

Licence: apache-2.0
This repository holds all oVirt related Ansible roles

Programming Languages

shell
77523 projects

Labels

Projects that are alternatives of or similar to Ovirt Ansible

Rocannon
Vim for Ansible playbooks: omni-completion, abbreviations, syntax, folding, K-docs, and colorscheme
Stars: ✭ 80 (-12.09%)
Mutual labels:  ansible
Devbox Golang
A Vagrant box with Ansible provisioning for setting up a vim-based Go(lang) development environment
Stars: ✭ 84 (-7.69%)
Mutual labels:  ansible
Learning Tools
A collection of tools and files for learning new technologies
Stars: ✭ 1,287 (+1314.29%)
Mutual labels:  ansible
Ansible Role Firewall
A role to manage iptables rules which doesn't suck.
Stars: ✭ 81 (-10.99%)
Mutual labels:  ansible
Ansible Elk Playbook
A playbook for setting up the ELK Stack + beats log shippers on Ubuntu 16.04 and above
Stars: ✭ 83 (-8.79%)
Mutual labels:  ansible
Docker Cloud Platform
使用Docker构建云平台,Docker云平台系列共三讲,Docker基础、Docker进阶、基于Docker的云平台方案。OpenStack+Docker+RestAPI+OAuth/HMAC+RabbitMQ/ZMQ+OpenResty/HAProxy/Nginx/APIGateway+Bootstrap/AngularJS+Ansible+K8S/Mesos/Marathon构建/探索微服务最佳实践。
Stars: ✭ 86 (-5.49%)
Mutual labels:  ansible
Mikado
🤖💨Mikado helps managing your AWS infrastructure for WordPress sites by defining an out-of-box, highly available, easy-to-deploy setup
Stars: ✭ 80 (-12.09%)
Mutual labels:  ansible
Docker Ansible Playbook
Docker Image of Ansible for executing ansible-playbook command against an externally mounted set of Ansible playbooks
Stars: ✭ 90 (-1.1%)
Mutual labels:  ansible
Ansible Haproxy
Ansible role to set up (the latest version of) HAProxy in Ubuntu systems
Stars: ✭ 83 (-8.79%)
Mutual labels:  ansible
Ansible Gpdpocket
Linux Installer for GPD Pocket
Stars: ✭ 88 (-3.3%)
Mutual labels:  ansible
Packer Ubuntu 1404
DEPRECATED - Packer Example - Ubuntu 14.04 Vagrant Box using Ansible provisioner
Stars: ✭ 81 (-10.99%)
Mutual labels:  ansible
Jjg Ansible Windows
[DEPRECATED] Windows shell provisioning script to bootstrap Ansible from within a Vagrant VM.
Stars: ✭ 82 (-9.89%)
Mutual labels:  ansible
Tower Operator
DEPRECATED: This project was moved and renamed to: https://github.com/ansible/awx-operator
Stars: ✭ 87 (-4.4%)
Mutual labels:  ansible
Openbsd Cookbooks
Setup environment in OpenBSD using Ansible playbook
Stars: ✭ 80 (-12.09%)
Mutual labels:  ansible
Ansible Podman Collections
Repository for Ansible content that can include playbooks, roles, modules, and plugins for use with the Podman tool
Stars: ✭ 89 (-2.2%)
Mutual labels:  ansible
Rocket.chat.ansible
Deploy Rocket.Chat with Ansible!
Stars: ✭ 80 (-12.09%)
Mutual labels:  ansible
Dotfiles
My precious configs
Stars: ✭ 85 (-6.59%)
Mutual labels:  ansible
Xsrv
[mirror] Install and manage self-hosted services/applications, on your own server(s) - ansible collection and utilities
Stars: ✭ 89 (-2.2%)
Mutual labels:  ansible
Awx Migrate
Tool to migrate AWX to a new instance
Stars: ✭ 89 (-2.2%)
Mutual labels:  ansible
Ubuntu1604 Cis
Ubuntu CIS Hardening Ansible Role
Stars: ✭ 88 (-3.3%)
Mutual labels:  ansible

Build Status

oVirt Ansible Roles

oVirt maintains multiple Ansible roles that can be deployed to easily configure and manage various parts of the oVirt infrastructure. Ansible roles provide a method of modularizing your Ansible code, in other words; it enables you to break up large playbooks into smaller reusable files. This enables you to have a separate role for each component of the infrustructure, and allows you to reuse and share roles with other users. For more information about roles, see Creating Reusable Playbooks in the Ansible Documentation.

Currently we have implemented following Ansible roles:

Installing the oVirt Roles

There are multiple methods to install the Ansible roles on your Ansible server.

Installing from a Package

Note: You must have the official oVirt repository enabled. For more information see the oVirt Deployment Options.

The Ansible roles are packaged into an RPM file that can be installed from the command line.

Run the following command to install all roles:

# yum install ovirt-ansible-roles

Run the following command to install specific role:

# yum install ovirt-ansible-infra

To search all available roles you can execute following command:

# yum search ovirt-ansible

By default the roles will be installed to /usr/share/ansible/roles.

The structure of the ovirt-ansible-roles package is as follows:

  • /usr/share/ansible/roles - stores the roles.
  • /usr/share/ansible/roles/{role_name} - stores the specific role.
  • /usr/share/doc/ovirt-ansible-roles/ - stores the examples, a basic overview and the licence.
  • /usr/share/doc/{role_name} - stores the documentation and examples specific to the role.

Installing using Galaxy

Ansible provides a command line utility to install Roles directory from the Galaxy Repository. See the Galaxy website for more information about Galaxy.

To install the roles using Galaxy, run the following from the command line:

# ansible-galaxy install oVirt.ovirt-ansible-roles

To install the specific role using Galaxy, run the following from the command line:

# ansible-galaxy install oVirt.infra

All roles are available under oVirt organization on Ansible Galaxy.

By default the roles will be installed to /etc/ansible/roles.

The structure of ovirt.ovirt-ansible-roles is as follows:

  • /etc/ansible/roles/ - stores the roles.
  • /etc/ansible/roles/{role_name} - stores the specifc role.
  • /etc/ansible/roles/{role_name}/examples - stores the examples, a basic overview

Getting Started

This section will guide you through creating and running your playbook against the engine. The following example connects to the engine on the local host and creates a new data center. The current working directory is /tmp.

Note: Ensure you have Python SDK installed on the machine running the playbook.

  1. Create a file in your working directory to store the engine's user password:
$ cat passwords.yml
---
engine_password: youruserpassword
  1. Encrypt the user password. You will be asked for a vault password.
$ ansible-vault encrypt passwords.yml
New Vault password:
Confirm New Vault password:
  1. Create a file that contains engine details such as the hostname, certificate, and user.
$ cat engine_vars.yml
---
engine_fqdn: example.engine.redhat.com
engine_user: [email protected]
engine_cafile: /etc/pki/ovirt-engine/ca.pem

Note: If you prefer, these variables can be added directly to the playbook instead.

  1. Create your playbook. To simplify this, you can copy and modify an example in /etc/ansible/roles/ovirt.ovirt-ansible-roles/examples or /usr/share/doc/ovirt-ansible-roles/examples depending on the method used to install the roles:
$ cat ovirt_infra.yml
---
- name: oVirt infra
  hosts: localhost
  connection: local
  gather_facts: false

  vars_files:
    # Contains variables to connect to the engine
    - engine_vars.yml
    # Contains encrypted `engine_password` variable using ansible-vault
    - passwords.yml

  pre_tasks:
    - name: Login to oVirt
      ovirt_auth:
        hostname: "{{ engine_fqdn }}"
        username: "{{ engine_user }}"
        password: "{{ engine_password }}"
        ca_file: "{{ engine_cafile | default(omit) }}"
        insecure: "{{ engine_insecure | default(true) }}"
      tags:
        - always

  vars:
    data_center_name: mydatacenter
    data_center_description: mydatacenter
    data_center_local: false
    compatibility_version: 4.2

  roles:
    - oVirt.infra

  post_tasks:
    - name: Logout from oVirt
      ovirt_auth:
        state: absent
        ovirt_auth: "{{ ovirt_auth }}"
      tags:
        - always
  1. Run the playbook.
$ ansible-playbook --ask-vault-pass ovirt_infra.yml

After the ansible-playbook playbook completes you will have a new data center named mydatacenter.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].