Add basic installation
This commit is contained in:
parent
43c40616de
commit
78b4cab5b3
7 changed files with 67 additions and 0 deletions
3
defaults/main.yml
Normal file
3
defaults/main.yml
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
# Default values for variables of the role
|
||||||
|
# variable_name: value
|
3
handlers/main.yml
Normal file
3
handlers/main.yml
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
# - name: Refresh aliases
|
||||||
|
# shell: newaliases
|
2
meta/.galaxy_install_info
Normal file
2
meta/.galaxy_install_info
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
install_date: Sun Nov 6 12:31:50 2022
|
||||||
|
version: ''
|
22
meta/main.yml
Normal file
22
meta/main.yml
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
---
|
||||||
|
galaxy_info:
|
||||||
|
author: Antonio J. Delgado (ajdelgado)
|
||||||
|
description: TODO - Description
|
||||||
|
|
||||||
|
# issue_tracker_url: https://github.com/uoi-io/ansible-galera/issues
|
||||||
|
|
||||||
|
license: GPLv3
|
||||||
|
|
||||||
|
min_ansible_version: "2.0"
|
||||||
|
|
||||||
|
github_branch: master
|
||||||
|
|
||||||
|
platforms:
|
||||||
|
- name: Ubuntu
|
||||||
|
versions:
|
||||||
|
- focal
|
||||||
|
- jammy
|
||||||
|
|
||||||
|
galaxy_tags: []# TODO
|
||||||
|
|
||||||
|
dependencies: []
|
3
tasks/configure.yml
Normal file
3
tasks/configure.yml
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
# - name: Ensure is configure
|
||||||
|
# something: something
|
27
tasks/install_ubuntu.yml
Normal file
27
tasks/install_ubuntu.yml
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
---
|
||||||
|
- name: Ensure keyring folder for apt exists
|
||||||
|
file:
|
||||||
|
path: /etc/apt/keyrings
|
||||||
|
state: directory
|
||||||
|
|
||||||
|
- name: Get Kubic (Podman) repo key
|
||||||
|
shell: "curl -fsSL https://download.opensuse.org/repositories/devel:kubic:libcontainers:stable/xUbuntu_{{ ansible_distribution_version }}/Release.key | gpg --dearmor | tee /etc/apt/keyrings/devel_kubic_libcontainers_unstable.gpg > /dev/null"
|
||||||
|
when:
|
||||||
|
- docker_command == 'podman'
|
||||||
|
- ansible_distribution_version|int < 20.10
|
||||||
|
|
||||||
|
- name: Add Kubic (Podman) repository
|
||||||
|
apt_repository:
|
||||||
|
repo: "deb [signed-by=/etc/apt/keyrings/devel_kubic_libcontainers_unstable.gpg] https://download.opensuse.org/repositories/devel:kubic:libcontainers:stable/xUbuntu_{{ ansible_distribution_version }}/ /"
|
||||||
|
filename: kubic-podman
|
||||||
|
update_cache: true
|
||||||
|
when:
|
||||||
|
- docker_command == 'podman'
|
||||||
|
- ansible_distribution_version|int < 20.10
|
||||||
|
|
||||||
|
- name: Install podman packages
|
||||||
|
package:
|
||||||
|
name:
|
||||||
|
- podman
|
||||||
|
- skopeo
|
||||||
|
- containernetworking-plugins
|
7
tasks/main.yml
Normal file
7
tasks/main.yml
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
---
|
||||||
|
- name: Ensure installation of podman (in Ubuntu)
|
||||||
|
include_tasks: install_ubuntu.yml
|
||||||
|
when: ansible_distribution == 'Ubuntu'
|
||||||
|
|
||||||
|
- name: Ensure configuration of podman
|
||||||
|
include_tasks: configure.yml
|
Loading…
Reference in a new issue