grlx.ingredients.service
The service ingredient handles the management of system services. Currently, this only supports systemd services.
service.masked
Section titled “service.masked”Checks if a service is masked and masks it if it is not
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.masked: - name: ssd-backup - userMode: trueservice.unmasked
Section titled “service.unmasked”Checks if a service is unmasked and unmasks it if it is not
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.unmasked: - name: ssd-backup - userMode: trueservice.running
Section titled “service.running”Checks if a service is running and starts it if it is not
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.running: - name: docker.service - userMode: falseservice.stopped
Section titled “service.stopped”Checks if a service is stopped and stops it if it is not
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.stopped: - name: docker.service - userMode: falseservice.enabled
Section titled “service.enabled”Checks if a service is enabled and enables it if it is not
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.enabled: - name: cronie.service - userMode: falseservice.disabled
Section titled “service.disabled”Checks if a service is disabled and disables it if it is not
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.disabled: - name: cronie.service - userMode: falseservice.restarted
Section titled “service.restarted”Restarts a service
Parameters
Section titled “Parameters”| parameter | type | required | description |
|---|---|---|---|
| name | string | yes | the name of the service unit |
| userMode | bool | no | to use service in user mode, false by default |
service.restarted: - name: cronie.service - userMode: false