bundlewrap/bundles/systemd-timers/metadata.py
mwiegand 275c6eb22b wip
2021-07-05 23:44:40 +02:00

27 lines
699 B
Python

defaults = {
'systemd-timers': {},
}
@metadata_reactor.provides(
'systemd/services',
)
def services(metadata):
return {
'systemd': {
'services': {
name: {
'content': {
'Unit':{
'Description': f'{name} timer service',
},
'Service': {
'ExecStart': config['command'],
},
},
'enabled': False,
'running': False,
} for name, config in metadata.get('systemd-timers').items()
},
},
}