Skip to content

Commit

Permalink
refactor(kitchen+inspec): move inline pillar to file
Browse files Browse the repository at this point in the history
  • Loading branch information
myii committed Jul 13, 2019
1 parent d623d7c commit 0005375
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 34 deletions.
36 changes: 2 additions & 34 deletions kitchen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,40 +123,8 @@ provisioner:
base:
'*':
- ufw
ufw.sls:
ufw:
enabled: True
settings:
loglevel: 'low'
applications:
MySQL:
comment: Allow MySQL
Postgresql:
limit: True
comment: Limit Postgresql
SSH223:
deny: True
comment: Deny Webscale SSH
'*':
deny: True
from_addr: 10.0.0.0/8
services:
'*':
deny: True
from_addr:
- 10.0.0.1
- 10.0.0.2
'22':
protocol: tcp
limit: True
comment: Limit SSH
'80':
protocol: tcp
deny: True
comment: Deny HTTP
'443':
protocol: tcp
comment: Allow HTTPS
pillars_from_files:
ufw.sls: test/salt/pillar/default.sls

verifier:
# https://www.inspec.io/
Expand Down
33 changes: 33 additions & 0 deletions test/salt/pillar/default.sls
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
ufw:
enabled: True
settings:
loglevel: 'low'
applications:
MySQL:
comment: Allow MySQL
Postgresql:
limit: True
comment: Limit Postgresql
SSH223:
deny: True
comment: Deny Webscale SSH
'*':
deny: True
from_addr: 10.0.0.0/8
services:
'*':
deny: True
from_addr:
- 10.0.0.1
- 10.0.0.2
'22':
protocol: tcp
limit: True
comment: Limit SSH
'80':
protocol: tcp
deny: True
comment: Deny HTTP
'443':
protocol: tcp
comment: Allow HTTPS

0 comments on commit 0005375

Please sign in to comment.