services: databases: Don't specify a default postgresql version.
Currently, if the postgresql package major version changes, this is going to break the service upon upgrade, because PostgreSQL will reject the data files from the differing major version of the service. Because it's important to either keep running a particular major version, or intentionally upgrade, I think the configuration would be better with no default. I think this is also going to be helpful when trying to assist users upgrading PostgreSQL. * gnu/services/databases.scm (<postgresql-configuration>): Remove default for postgresql. (postgresql-service-type): Remove the default value. * gnu/tests/databases.scm (%postgresql-os): Update accordingly. * gnu/tests/guix.scm (%guix-data-service-os): Update accordingly. * gnu/tests/monitoring.scm (%zabbix-os): Update accordingly. * gnu/tests/web.scm (patchwork-os): Update accordingly. * doc/guix.texi (PostgreSQL): Update accordingly.master
parent
21b712acc7
commit
bdcf4d88d5
|
@ -18457,7 +18457,9 @@ The following example describes a PostgreSQL service with the default
|
|||
configuration.
|
||||
|
||||
@lisp
|
||||
(service postgresql-service-type)
|
||||
(service postgresql-service-type
|
||||
(postgresql-configuration
|
||||
(postgresql postgresql-10)))
|
||||
@end lisp
|
||||
|
||||
If the services fails to start, it may be due to an incompatible
|
||||
|
@ -18483,7 +18485,7 @@ Data type representing the configuration for the
|
|||
@code{postgresql-service-type}.
|
||||
|
||||
@table @asis
|
||||
@item @var{postgresql} (default: @code{postgresql})
|
||||
@item @var{postgresql}
|
||||
PostgreSQL package to use for the service.
|
||||
|
||||
@item @var{port} (default: @code{5432})
|
||||
|
|
|
@ -147,8 +147,7 @@ host all all ::1/128 md5"))
|
|||
(define-record-type* <postgresql-configuration>
|
||||
postgresql-configuration make-postgresql-configuration
|
||||
postgresql-configuration?
|
||||
(postgresql postgresql-configuration-postgresql ;<package>
|
||||
(default postgresql))
|
||||
(postgresql postgresql-configuration-postgresql) ;<package>
|
||||
(port postgresql-configuration-port
|
||||
(default 5432))
|
||||
(locale postgresql-configuration-locale
|
||||
|
@ -279,8 +278,7 @@ host all all ::1/128 md5"))
|
|||
(service-extension account-service-type
|
||||
(const %postgresql-accounts))
|
||||
(service-extension profile-service-type
|
||||
(compose list postgresql-configuration-postgresql))))
|
||||
(default-value (postgresql-configuration))))
|
||||
(compose list postgresql-configuration-postgresql))))))
|
||||
|
||||
(define-deprecated (postgresql-service #:key (postgresql postgresql)
|
||||
(port 5432)
|
||||
|
|
|
@ -215,7 +215,9 @@
|
|||
|
||||
(define %postgresql-os
|
||||
(simple-operating-system
|
||||
(service postgresql-service-type)))
|
||||
(service postgresql-service-type
|
||||
(postgresql-configuration
|
||||
(postgresql postgresql-10)))))
|
||||
|
||||
(define (run-postgresql-test)
|
||||
"Run tests in %POSTGRESQL-OS."
|
||||
|
|
|
@ -156,6 +156,7 @@
|
|||
(service dhcp-client-service-type)
|
||||
(service postgresql-service-type
|
||||
(postgresql-configuration
|
||||
(postgresql postgresql-10)
|
||||
(config-file
|
||||
(postgresql-config-file
|
||||
(hba-file
|
||||
|
|
|
@ -307,7 +307,9 @@ zabbix||{}
|
|||
(let ((base-os
|
||||
(simple-operating-system
|
||||
(service dhcp-client-service-type)
|
||||
(service postgresql-service-type)
|
||||
(service postgresql-service-type
|
||||
(postgresql-configuration
|
||||
(postgresql postgresql-10)))
|
||||
(service zabbix-front-end-service-type
|
||||
(zabbix-front-end-configuration
|
||||
(db-password "zabbix")))
|
||||
|
|
|
@ -567,7 +567,9 @@ HTTP-PORT."
|
|||
(config
|
||||
(httpd-config-file
|
||||
(listen '("8080"))))))
|
||||
(service postgresql-service-type)
|
||||
(service postgresql-service-type
|
||||
(postgresql-configuration
|
||||
(postgresql postgresql-10)))
|
||||
(service patchwork-service-type
|
||||
(patchwork-configuration
|
||||
(patchwork patchwork)
|
||||
|
|
Reference in New Issue