mirror of
https://github.com/GeekOops/geekoops-pureftpd.git
synced 2024-05-08 09:21:25 +00:00
Revive the role
Update the role to Leap 15.3 and 15.4 and switch the molecule test from using foreign images to building the test images using custom Dockerfiles.
This commit is contained in:
parent
179a54125b
commit
88b1306386
|
@ -2,6 +2,8 @@
|
|||
|
||||
galaxy_info:
|
||||
author: Felix Niederwanger
|
||||
role_name: pureftpd
|
||||
namespace: geekoops
|
||||
description: Install and configure PureFTPd
|
||||
company: SUSE
|
||||
# issue_tracker_url: http://example.com/issue/tracker
|
||||
|
@ -13,7 +15,8 @@ galaxy_info:
|
|||
platforms:
|
||||
- name: opensuse
|
||||
versions:
|
||||
- 15.2
|
||||
- 15.3
|
||||
- 15.4
|
||||
|
||||
galaxy_tags: ['ftp']
|
||||
|
||||
|
|
7
molecule/default/Dockerfile.leap15_3
Normal file
7
molecule/default/Dockerfile.leap15_3
Normal file
|
@ -0,0 +1,7 @@
|
|||
FROM registry.opensuse.org/opensuse/leap:15.3
|
||||
|
||||
# Install systemd and development tools, clear cache
|
||||
RUN zypper in -y systemd systemd-sysvinit firewalld python3 python3-firewall curl && rm -rf /var/cache/*
|
||||
|
||||
# Start container with systemd
|
||||
ENTRYPOINT ["/usr/sbin/init"]
|
7
molecule/default/Dockerfile.leap15_4
Normal file
7
molecule/default/Dockerfile.leap15_4
Normal file
|
@ -0,0 +1,7 @@
|
|||
FROM registry.opensuse.org/opensuse/leap:15.4
|
||||
|
||||
# Install systemd and development tools, clear cache
|
||||
RUN zypper in -y systemd systemd-sysvinit firewalld python3 python3-firewall curl && rm -rf /var/cache/*
|
||||
|
||||
# Start container with systemd
|
||||
ENTRYPOINT ["/usr/sbin/init"]
|
|
@ -6,6 +6,11 @@
|
|||
include_role:
|
||||
name: "geekoops-pureftpd"
|
||||
## Setup test enviroment
|
||||
- name: Enable firewall
|
||||
systemd:
|
||||
name: firewalld
|
||||
state: started
|
||||
enabled: true
|
||||
# Test file 1 is accessible (0754), test file 2 not (0750)
|
||||
- name: Deploy test file
|
||||
copy:
|
||||
|
|
|
@ -4,14 +4,23 @@ dependency:
|
|||
driver:
|
||||
name: docker
|
||||
platforms:
|
||||
- name: leap15_2
|
||||
image: grisu48/leap-ansible
|
||||
pre_build_image: true
|
||||
- name: leap15_3
|
||||
image: registry.opensuse.org/opensuse/leap:15.3
|
||||
dockerfile: Dockerfile.leap15_3
|
||||
command: ${MOLECULE_DOCKER_COMMAND:-"/usr/sbin/init"}
|
||||
privileged: true
|
||||
volumes:
|
||||
- /sys/fs/cgroup:/sys/fs/cgroup:ro
|
||||
capabilities:
|
||||
- SYS_ADMIN
|
||||
tmpfs:
|
||||
- /run
|
||||
- /tmp
|
||||
- name: leap15_4
|
||||
image: registry.opensuse.org/opensuse/leap:15.4
|
||||
dockerfile: Dockerfile.leap15_4
|
||||
command: ${MOLECULE_DOCKER_COMMAND:-"/usr/sbin/init"}
|
||||
privileged: true
|
||||
volumes:
|
||||
- /sys/fs/cgroup:/sys/fs/cgroup:ro
|
||||
tmpfs:
|
||||
- /run
|
||||
- /tmp
|
||||
|
@ -19,8 +28,12 @@ provisioner:
|
|||
name: ansible
|
||||
inventory:
|
||||
host_vars:
|
||||
leap15_2:
|
||||
leap15_3:
|
||||
ftp_dir: "/srv/ftp"
|
||||
config_firewall: true
|
||||
leap15_4:
|
||||
ftp_dir: "/srv/ftp"
|
||||
config_firewall: true
|
||||
verifier:
|
||||
name: testinfra
|
||||
lint:
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
group: root
|
||||
mode: 0744
|
||||
notify: restart pureftpd
|
||||
tags: ['ftp']
|
||||
- name: Ensure PureFTPd service is started and enabled
|
||||
systemd:
|
||||
name: "{{pureftpd_service}}"
|
||||
|
@ -27,5 +28,5 @@
|
|||
enabled: true
|
||||
tags: ['ftp', 'systemd']
|
||||
|
||||
- include: firewall.yml
|
||||
- include_tasks: firewall.yml
|
||||
when: config_firewall == true
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
---
|
||||
# openSUSE Leap 15.2 specific variables
|
||||
# openSUSE Leap 15.3 specific variables
|
||||
|
||||
## Software packages
|
||||
|
6
vars/openSUSE Leap_15.4.yml
Normal file
6
vars/openSUSE Leap_15.4.yml
Normal file
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
# openSUSE Leap 15.4 specific variables
|
||||
|
||||
## Software packages
|
||||
|
||||
packages: ['pure-ftpd']
|
Loading…
Reference in a new issue