Skip to content

Commit

Permalink
feat(formula): add lynis-formula
Browse files Browse the repository at this point in the history
  • Loading branch information
myii committed Sep 11, 2020
1 parent 88be532 commit 135ee73
Show file tree
Hide file tree
Showing 4 changed files with 88 additions and 3 deletions.
1 change: 1 addition & 0 deletions pillar.example
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ ssf:
- locale
- logrotate
- lvm
- lynis
- mattermost
- maven
- mongodb
Expand Down
19 changes: 17 additions & 2 deletions ssf/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ ssf_node_anchors:
# An alternative method could be to use:
# `git describe --abbrev=0 --tags`
# yamllint disable rule:line-length rule:quoted-strings
title: "ci(travis): merge Rubocop linter into main lint job [skip ci]"
body: '* Automated using https://github.com/myii/ssf-formula/pull/252'
title: "chore: standardise structure"
body: '* Automated using https://github.com/myii/ssf-formula/pull/253'
# yamllint enable rule:line-length rule:quoted-strings
github:
owner: 'saltstack-formulas'
Expand Down Expand Up @@ -649,6 +649,21 @@ ssf:
1:
<<: *isk_suite_default
name: 'loop5-loop6'
lynis:
<<: *formula_default
context:
<<: *context_default
inspec_suites_kitchen:
<<: *isk_default
1:
<<: *isk_suite_default
name: 'share'
2:
<<: *isk_suite_default
name: 'repo'
3:
<<: *isk_suite_default
name: 'amazonlinux'
mattermost: *formula_default
maven:
<<: *formula_default
Expand Down
3 changes: 2 additions & 1 deletion ssf/files/tofs_.github/docs/CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,7 @@ These formulas are already compatible with semantic-release *and* have global ``
#. `letsencrypt-formula <https://github.com/saltstack-formulas/letsencrypt-formula>`_
#. `libvirt-formula <https://github.com/saltstack-formulas/libvirt-formula>`_
#. `lvm-formula <https://github.com/saltstack-formulas/lvm-formula>`_
#. `lynis-formula <https://github.com/saltstack-formulas/lynis-formula>`_
#. `maven-formula <https://github.com/saltstack-formulas/maven-formula>`_
#. `mongodb-formula <https://github.com/saltstack-formulas/mongodb-formula>`_
#. `nginx-formula <https://github.com/saltstack-formulas/nginx-formula>`_
Expand Down Expand Up @@ -217,7 +218,7 @@ These formulas are already compatible with semantic-release *and* have global ``

These formulas are also compatible with semantic-release:

52. `apache-formula <https://github.com/saltstack-formulas/apache-formula>`_
53. `apache-formula <https://github.com/saltstack-formulas/apache-formula>`_
#. `apt-cacher-formula <https://github.com/saltstack-formulas/apt-cacher-formula>`_
#. `cert-formula <https://github.com/saltstack-formulas/cert-formula>`_
#. `chrony-formula <https://github.com/saltstack-formulas/chrony-formula>`_
Expand Down
68 changes: 68 additions & 0 deletions ssf/formulas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2460,6 +2460,74 @@ ssf:
- [amazonlinux , 1 , 2018.3, 2, loop5-loop6]
- [arch-base , latest, 2018.3, 2, loop5-loop6]
semrel_files: *semrel_files_default
lynis:
context:
codeowners:
entries:
global:
- '*': '@n-rodriguez'
git:
github:
repo: 'lynis-formula'
inspec_suites_kitchen:
0:
inspec_yml:
# depends: *depends_on_suite_share
summary: >-
Verify that the lynis formula is setup and configured correctly
(installed using git)
provisioner:
pillars_from_files:
- .sls: 'test/salt/pillar/default.sls'
# state_top:
# - '*':
# - ._mapdata
# - .
1:
includes: *includes_NONE
inspec_yml:
summary: >-
shared resources
2:
excludes: *platforms_os_amazonlinux_new
inspec_yml:
summary: >-
Verify that the lynis formula is setup and configured correctly
(installed as a package)
provisioner:
pillars_from_files:
- .sls: 'test/salt/pillar/repo.sls'
3:
includes: *platforms_os_amazonlinux_new
provisioner:
dependencies: *dependencies_epel
pillars_from_files:
- .sls: 'test/salt/pillar/repo.sls'
state_top:
- '*':
- epel
- .
verifier:
inspec_tests:
- repo
inspec_suites_matrix:
- default
- repo
- amazonlinux
platforms: *platforms_new
# Based on `*platforms_matrix_new_mainly_master_images`
platforms_matrix:
# [os , os_ver, salt_ver, py_ver, inspec_suite]
- [debian , 10 , master, 3, default]
- [ubuntu , 20.04, master, 3, repo]
# - [ubuntu , 18.04, master, 3, default]
- [centos , 8 , master, 3, default]
- [fedora , 32 , master, 3, repo]
# - [fedora , 31 , master, 3, default]
- [opensuse/leap, 15.2 , master, 3, default]
- [amazonlinux , 2 , master, 3, amazonlinux]
- [arch-base , latest, 2019.2, 2, repo]
semrel_files: *semrel_files_default
mattermost:
context:
codeowners:
Expand Down

0 comments on commit 135ee73

Please sign in to comment.