|
| 1 | +# (Optional) A short one line summary of the layer |
| 2 | +summary: Manage the HAPRoxy process |
| 3 | + |
| 4 | +# (Optional) A list of services managed by this configuration layer |
| 5 | +services: |
| 6 | + |
| 7 | + haproxy: |
| 8 | + |
| 9 | + # (Required) Control how this service definition is combined with any |
| 10 | + # other pre-existing definition with the same name in the Pebble plan. |
| 11 | + # |
| 12 | + # The value 'merge' will ensure that values in this layer specification |
| 13 | + # are merged over existing definitions, whereas 'replace' will entirely |
| 14 | + # override the existing service spec in the plan with the same name. |
| 15 | + override: replace |
| 16 | + |
| 17 | + # (Required in combined layer) The command to run the service. It is executed |
| 18 | + # directly, not interpreted by a shell, and may be optionally suffixed by default |
| 19 | + # arguments within "[" and "]" which may be overriden via --args. |
| 20 | + # Example: /usr/bin/somedaemon --db=/db/path [ --port 8080 ] |
| 21 | + command: /var/lib/pebble/default/run-haproxy |
| 22 | + |
| 23 | + |
| 24 | + # (Optional) Control whether the service is started automatically when |
| 25 | + # Pebble starts. Default is "disabled". |
| 26 | + startup: enabled |
| 27 | + |
| 28 | + # (Optional) Username for starting service as a different user. It is |
| 29 | + # an error if the user doesn't exist. |
| 30 | + # user: haproxy |
| 31 | + |
| 32 | + # (Optional) Group name for starting service as a different user. It is |
| 33 | + # an error if the group doesn't exist. |
| 34 | + # group: haproxy |
| 35 | + |
| 36 | + # (Optional) Defines what happens when the service exits with a zero |
| 37 | + # exit code. Possible values are: "restart" (default) which restarts |
| 38 | + # the service after the backoff delay, "shutdown" which shuts down and |
| 39 | + # exits the Pebble server, and "ignore" which does nothing further. |
| 40 | + on-success: restart |
| 41 | + |
| 42 | + # (Optional) Defines what happens when the service exits with a nonzero |
| 43 | + # exit code. Possible values are: "restart" (default) which restarts |
| 44 | + # the service after the backoff delay, "shutdown" which shuts down and |
| 45 | + # exits the Pebble server, and "ignore" which does nothing further. |
| 46 | + on-failure: restart |
| 47 | + |
| 48 | + controller: |
| 49 | + |
| 50 | + # (Required) Control how this service definition is combined with any |
| 51 | + # other pre-existing definition with the same name in the Pebble plan. |
| 52 | + # |
| 53 | + # The value 'merge' will ensure that values in this layer specification |
| 54 | + # are merged over existing definitions, whereas 'replace' will entirely |
| 55 | + # override the existing service spec in the plan with the same name. |
| 56 | + override: replace |
| 57 | + |
| 58 | + # (Required in combined layer) The command to run the service. It is executed |
| 59 | + # directly, not interpreted by a shell, and may be optionally suffixed by default |
| 60 | + # arguments within "[" and "]" which may be overriden via --args. |
| 61 | + # Example: /usr/bin/somedaemon --db=/db/path [ --port 8080 ] |
| 62 | + command: /var/lib/pebble/default/run-controller |
| 63 | + |
| 64 | + |
| 65 | + # (Optional) Control whether the service is started automatically when |
| 66 | + # Pebble starts. Default is "disabled". |
| 67 | + startup: enabled |
| 68 | + |
| 69 | + # (Optional) Username for starting service as a different user. It is |
| 70 | + # an error if the user doesn't exist. |
| 71 | + #user: haproxy |
| 72 | + |
| 73 | + # (Optional) Group name for starting service as a different user. It is |
| 74 | + # an error if the group doesn't exist. |
| 75 | + #group: haproxy |
| 76 | + |
| 77 | + # (Optional) Defines what happens when the service exits with a zero |
| 78 | + # exit code. Possible values are: "restart" (default) which restarts |
| 79 | + # the service after the backoff delay, "shutdown" which shuts down and |
| 80 | + # exits the Pebble server, and "ignore" which does nothing further. |
| 81 | + on-success: restart |
| 82 | + |
| 83 | + # (Optional) Defines what happens when the service exits with a nonzero |
| 84 | + # exit code. Possible values are: "restart" (default) which restarts |
| 85 | + # the service after the backoff delay, "shutdown" which shuts down and |
| 86 | + # exits the Pebble server, and "ignore" which does nothing further. |
| 87 | + on-failure: restart |
| 88 | + |
| 89 | + after: |
| 90 | + - haproxy |
| 91 | + |
| 92 | +checks: |
| 93 | + check-haproxy: |
| 94 | + # (Required) Control how this check definition is combined with any |
| 95 | + # other pre-existing definition with the same name in the Pebble plan. |
| 96 | + # |
| 97 | + # The value 'merge' will ensure that values in this layer specification |
| 98 | + # are merged over existing definitions, whereas 'replace' will entirely |
| 99 | + # override the existing check spec in the plan with the same name. |
| 100 | + override: replace |
| 101 | + http: |
| 102 | + # (Required) URL to fetch, for example "https://example.com/foo". |
| 103 | + url: http://127.0.0.1:1042/healthz |
0 commit comments