|
53 | 53 | make_int_option_default("Service", "StartLimitBurst", NULL, true, \ |
54 | 54 | &(config->StartLimitBurst), 20) |
55 | 55 |
|
| 56 | +#define OPTION_SYSTEMD_EXECRELOAD(config) \ |
| 57 | + make_strbuf_option_default("Service", "ExecReload", NULL, true, BUFSIZE, \ |
| 58 | + config->ExecReload, "/usr/bin/pg_autoctl reload") |
| 59 | + |
56 | 60 | #define OPTION_SYSTEMD_WANTEDBY(config) \ |
57 | 61 | make_strbuf_option_default("Install", "WantedBy", NULL, true, BUFSIZE, \ |
58 | 62 | config->WantedBy, "multi-user.target") |
|
66 | 70 | OPTION_SYSTEMD_EXECSTART(config), \ |
67 | 71 | OPTION_SYSTEMD_RESTART(config), \ |
68 | 72 | OPTION_SYSTEMD_STARTLIMITBURST(config), \ |
| 73 | + OPTION_SYSTEMD_EXECRELOAD(config), \ |
69 | 74 | OPTION_SYSTEMD_WANTEDBY(config), \ |
70 | 75 | INI_OPTION_LAST \ |
71 | 76 | } |
@@ -108,6 +113,7 @@ systemd_config_init(SystemdServiceConfig *config, const char *pgdata) |
108 | 113 |
|
109 | 114 | /* adjust the program to the current full path of argv[0] */ |
110 | 115 | sformat(config->ExecStart, BUFSIZE, "%s run", pg_autoctl_program); |
| 116 | + sformat(config->ExecReload, BUFSIZE, "%s reload", pg_autoctl_program); |
111 | 117 |
|
112 | 118 | if (!ini_validate_options(systemdOptions)) |
113 | 119 | { |
|
0 commit comments