Skip to content

Commit 68c729a

Browse files
committed
fix: added support for Ubuntu 16.04 to fix issue #5
ft: added Ubuntu 16.04 to pipeline test in develop branch
1 parent 7f72f61 commit 68c729a

File tree

10 files changed

+89
-1
lines changed

10 files changed

+89
-1
lines changed

.github/workflows/develop.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
matrix:
3030
python: [2.7, 3.9]
3131
ansible: ["~=2.9", "~=3.4", "~=4.1"]
32-
scenario: ["centos-8", "ubuntu-21.04"]
32+
scenario: ["centos-8", "ubuntu-21.04", "ubuntu-16.04"]
3333

3434
steps:
3535
- name: Check out the codebase.

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# VERSION
22

3+
## 1.0.2
4+
5+
* added support for Ubuntu 16.04 to fix issue #5
6+
* added Ubuntu 16.04 to pipeline test in develop branch
7+
38
## 1.0.1
49

510
* fixed issue #2

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ This role work on RedHat, CentOS, Debian and Ubuntu distributions
2525
* 7
2626
* 8
2727
* Ubuntu
28+
* 16.*
2829
* 18.*
2930
* 20.*
3031
* 21.*

meta/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ galaxy_info:
2020
- bullseye
2121
- name: Ubuntu
2222
version:
23+
- xenial
2324
- bionic
2425
- focal
2526
- hirsute

molecule/ubuntu-16.04/INSTALL.rst

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
*******
2+
Docker driver installation guide
3+
*******
4+
5+
Requirements
6+
============
7+
8+
* General molecule dependencies (see https://molecule.readthedocs.io/en/latest/installation.html)
9+
* Docker Engine
10+
* docker-py
11+
* docker
12+
13+
Install
14+
=======
15+
16+
$ sudo pip install docker-py

molecule/ubuntu-16.04/converge.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
- name: Converge
3+
hosts: all
4+
5+
pre_tasks:
6+
- name: Update apt cache.
7+
apt: update_cache=true cache_valid_time=600
8+
when: ansible_os_family == 'Debian'
9+
changed_when: false
10+
11+
tasks:
12+
- name: "Include christiangda.epel_repo"
13+
include_role:
14+
name: christiangda.epel_repo
15+
16+
roles:
17+
- role: christiangda.epel_repo
18+
when: >
19+
ansible_os_family == 'RedHat' and (
20+
ansible_distribution == 'CentOS' or
21+
ansible_distribution == 'RedHat' or
22+
ansible_distribution == 'Amazon'
23+
)
24+
changed_when: false
25+
- role: christiangda.awscli

molecule/ubuntu-16.04/molecule.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
dependency:
3+
name: galaxy
4+
5+
driver:
6+
name: docker
7+
8+
provisioner:
9+
name: ansible
10+
# log: true
11+
12+
verifier:
13+
name: ansible
14+
15+
scenario:
16+
name: ubuntu-16.04
17+
18+
platforms:
19+
- name: ubuntu-16.04
20+
image: ubuntu:16.04
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
---
2+
- src: christiangda.epel_repo
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import os
2+
3+
import testinfra.utils.ansible_runner
4+
5+
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
6+
os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all')
7+
8+
9+
def test_hosts_file(host):
10+
f = host.file('/etc/hosts')
11+
12+
assert f.exists
13+
assert f.user == 'root'
14+
assert f.group == 'root'

vars/ubuntu-16.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
cli_dependencies_packages:
3+
- python3-setuptools
4+
- python3-pip

0 commit comments

Comments
 (0)