Skip to content
This repository was archived by the owner on Nov 17, 2020. It is now read-only.

Commit 4cc5276

Browse files
authored
Merge pull request #34 from dev-sec/remove_eol_os
remove eol'd OS and add new
2 parents 0e4534e + c608e02 commit 4cc5276

File tree

5 files changed

+70
-44
lines changed

5 files changed

+70
-44
lines changed

.kitchen.vagrant.yml

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,30 @@ transport:
1919
max_ssh_sessions: 5
2020

2121
platforms:
22-
- name: ubuntu-14.04
2322
- name: ubuntu-16.04
24-
- name: centos-6.8
25-
- name: centos-7.3
26-
- name: oracle-6.8
27-
- name: oracle-7.3
28-
- name: debian-7.11
29-
- name: debian-8.7
23+
driver_config:
24+
box: bento/ubuntu-16.04
25+
- name: ubuntu-18.04
26+
driver_config:
27+
box: bento/ubuntu-18.04
28+
- name: centos-6
29+
driver_config:
30+
box: bento/centos-6
31+
- name: centos-7
32+
driver_config:
33+
box: bento/centos-7
34+
- name: oracle-6
35+
driver_config:
36+
box: bento/oracle-6
37+
- name: oracle-7
38+
driver_config:
39+
box: bento/oracle-7
40+
- name: debian-9
41+
driver_config:
42+
box: bento/debian-9
43+
- name: amazon
44+
driver_config:
45+
box: bento/amazonlinux-2
3046

3147
verifier:
3248
name: inspec

.kitchen.yml

Lines changed: 26 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -39,39 +39,46 @@ platforms:
3939
driver:
4040
image: rndmh3ro/docker-oracle7-ansible:latest
4141
platform: centos
42-
- name: ubuntu1404-ansible-latest
43-
driver:
44-
image: rndmh3ro/docker-ubuntu1404-ansible:latest
45-
platform: ubuntu
42+
run_command: /sbin/init
43+
provision_command:
44+
- systemctl enable ssh.service
4645
- name: ubuntu1604-ansible-latest
4746
driver:
4847
image: rndmh3ro/docker-ubuntu1604-ansible:latest
4948
platform: ubuntu
50-
- name: debian7-ansible-latest
51-
driver:
52-
image: rndmh3ro/docker-debian7-ansible:latest
53-
platform: debian
54-
intermediate_instructions:
55-
- RUN /usr/bin/apt-get update
56-
- RUN /usr/bin/apt-get install -y procps
57-
- name: debian8-ansible-latest
49+
run_command: /sbin/init
50+
- name: ubuntu1804-ansible-latest
5851
driver:
59-
image: rndmh3ro/docker-debian8-ansible:latest
60-
platform: debian
61-
intermediate_instructions:
62-
- RUN /usr/bin/apt-get update
63-
- RUN /usr/bin/apt-get install -y procps
64-
pid_one_command: /bin/systemd
52+
image: rndmh3ro/docker-ubuntu1804-ansible:latest
53+
platform: ubuntu
6554
- name: debian9-ansible-latest
6655
driver:
6756
image: rndmh3ro/docker-debian9-ansible:latest
6857
platform: debian
58+
run_command: /sbin/init
59+
provision_command:
60+
- apt install -y systemd-sysv
61+
- systemctl enable ssh.service
62+
- name: amazon-ansible-latest
63+
driver:
64+
image: rndmh3ro/docker-amazon-ansible:latest
65+
platform: centos
66+
run_command: /sbin/init
67+
#- name: amazon-ansible-latest
68+
# driver:
69+
# image: rndmh3ro/docker-amazon-ansible:latest
70+
# platform: centos
71+
# run_command: /sbin/init
72+
# provision_command:
73+
# - sed -i 's/UsePAM yes/UsePAM no/g' /etc/ssh/sshd_config
74+
# - systemctl enable sshd.service
6975

7076
verifier:
7177
name: inspec
7278
sudo: true
7379
inspec_tests:
74-
- https://github.com/dev-sec/mysql-baseline
80+
- ../mysql-baseline
81+
# - https://github.com/dev-sec/mysql-baseline
7582

7683
suites:
7784
- name: mysql

.travis.yml

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -28,25 +28,25 @@ env:
2828
# init: /lib/systemd/systemd
2929
# run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
3030

31-
# - distro: ubuntu1404
32-
# version: latest
33-
# run_opts: "--privileged"
34-
# init: /sbin/init
35-
36-
- distro: debian7
31+
- distro: ubuntu1804
3732
version: latest
38-
run_opts: "--privileged"
39-
init: /sbin/init
33+
init: /lib/systemd/systemd
34+
run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
4035

41-
# - distro: debian8
36+
# - distro: debian9
4237
# version: latest
43-
# init: /bin/systemd
38+
# init: /lib/systemd/systemd
4439
# run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
4540

46-
# - distro: debian9
47-
# version: latest
48-
# init: /lib/systemd/systemd
49-
# run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
41+
- distro: amazon
42+
init: /lib/systemd/systemd
43+
version: latest
44+
run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
45+
46+
- distro: fedora
47+
init: /lib/systemd/systemd
48+
version: latest
49+
run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
5050

5151
before_install:
5252
# Pull container
@@ -58,7 +58,7 @@ script:
5858
- 'docker run --detach --volume="${PWD}":/etc/ansible/roles/ansible-mysql-hardening:ro ${run_opts} rndmh3ro/docker-${distro}-ansible:${version} "${init}" > "${container_id}"'
5959

6060
# Install ansible galaxy requirements
61-
- 'docker exec "$(cat ${container_id})" ansible-galaxy install -r /etc/ansible/roles/ansible-mysql-hardening/requirements.yml -p /etc/ansible/roles/'
61+
- 'docker exec "$(cat ${container_id})" ansible-galaxy install -c -r /etc/ansible/roles/ansible-mysql-hardening/requirements.yml -p /etc/ansible/roles/'
6262

6363
# Test role.
6464
- 'travis_wait docker exec "$(cat ${container_id})" ansible-playbook /etc/ansible/roles/ansible-mysql-hardening/default.yml'

meta/main.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ galaxy_info:
1212
- 7
1313
- name: Ubuntu
1414
versions:
15-
- precise
16-
- trusty
1715
- xenial
16+
- bionic
1817
- name: Debian
1918
versions:
20-
- wheezy
2119
- jessie
20+
- name: Amazon
21+
- name: Fedora
2222
galaxy_tags:
2323
- system
2424
- security

vars/Fedora.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
mysql_daemon: mysqld
2+
mysql_hardening_mysql_conf_file: '/etc/my.cnf'
3+
mysql_hardening_mysql_confd_dir: '/etc/my.cnf.d'

0 commit comments

Comments
 (0)