ShellPath returns a POSIX shell command that prepends typical Postgres executable paths to the PATH variable.
(postgresVersion int32)
| 265 | |
| 266 | // ShellPath returns a POSIX shell command that prepends typical Postgres executable paths to the PATH variable. |
| 267 | func ShellPath(postgresVersion int32) string { |
| 268 | return fmt.Sprintf(`PATH="`+ |
| 269 | strings.Join([]string{ |
| 270 | `/usr/lib/postgresql/%[1]d/bin`, // Debian |
| 271 | `/usr/libexec/postgresql%[1]d`, // Alpine |
| 272 | `/usr/pgsql-%[1]d/bin`, // Red Hat |
| 273 | }, ":")+ |
| 274 | `${PATH+:${PATH}}"`, postgresVersion) |
| 275 | } |
| 276 | |
| 277 | // reloadCommand returns an entrypoint that convinces PostgreSQL to reload |
| 278 | // certificate files when they change. The process will appear as name in `ps` |
no outgoing calls