bundles/openssh: move iptables rules to metadata reactor
All checks were successful
bundlewrap/pipeline/head This commit looks good
All checks were successful
bundlewrap/pipeline/head This commit looks good
This commit is contained in:
parent
b943d2d465
commit
c9f008ad82
3 changed files with 14 additions and 6 deletions
|
@ -1,3 +1,5 @@
|
|||
from bundlewrap.metadata import atomic
|
||||
|
||||
defaults = {
|
||||
'apt': {
|
||||
'packages': {
|
||||
|
@ -12,3 +14,15 @@ defaults = {
|
|||
},
|
||||
},
|
||||
}
|
||||
|
||||
@metadata_reactor.provides(
|
||||
'iptables/port_rules/22',
|
||||
)
|
||||
def iptables(metadata):
|
||||
return {
|
||||
'iptables': {
|
||||
'port_rules': {
|
||||
'22': atomic(metadata.get('openssh/restrict-to', set('*'))),
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue