about summary refs log tree commit diff
path: root/nixpkgs/nixos/modules/services/misc/gitlab.nix
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2021-06-30 13:44:37 +0000
committerAlyssa Ross <hi@alyssa.is>2021-06-30 13:44:37 +0000
commit16f676d6bbd4f930b0017ccb20cebe5a29e17545 (patch)
tree0d554b4f16bdef502035b743457fc29ffcc5e7f7 /nixpkgs/nixos/modules/services/misc/gitlab.nix
parente7caacc4c122b7641bb66a4c2595289347a4996c (diff)
parent3a8d7958a610cd3fec3a6f424480f91a1b259185 (diff)
downloadnixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.tar
nixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.tar.gz
nixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.tar.bz2
nixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.tar.lz
nixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.tar.xz
nixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.tar.zst
nixlib-16f676d6bbd4f930b0017ccb20cebe5a29e17545.zip
Merge commit '3a8d7958a610cd3fec3a6f424480f91a1b259185'
Diffstat (limited to 'nixpkgs/nixos/modules/services/misc/gitlab.nix')
-rw-r--r--nixpkgs/nixos/modules/services/misc/gitlab.nix8
1 files changed, 6 insertions, 2 deletions
diff --git a/nixpkgs/nixos/modules/services/misc/gitlab.nix b/nixpkgs/nixos/modules/services/misc/gitlab.nix
index b4fc4bf4b2cc..237c20e4b7f6 100644
--- a/nixpkgs/nixos/modules/services/misc/gitlab.nix
+++ b/nixpkgs/nixos/modules/services/misc/gitlab.nix
@@ -10,7 +10,7 @@ let
   postgresqlPackage = if config.services.postgresql.enable then
                         config.services.postgresql.package
                       else
-                        pkgs.postgresql;
+                        pkgs.postgresql_12;
 
   gitlabSocket = "${cfg.statePath}/tmp/sockets/gitlab.socket";
   gitalySocket = "${cfg.statePath}/tmp/sockets/gitaly.socket";
@@ -462,7 +462,7 @@ in {
       };
 
       port = mkOption {
-        type = types.int;
+        type = types.port;
         default = 8080;
         description = ''
           GitLab server port for copy-paste URLs, e.g. 80 or 443 if you're
@@ -841,6 +841,10 @@ in {
         assertion = cfg.secrets.jwsFile != null;
         message = "services.gitlab.secrets.jwsFile must be set!";
       }
+      {
+        assertion = versionAtLeast postgresqlPackage.version "12.0.0";
+        message = "PostgreSQL >=12 is required to run GitLab 14.";
+      }
     ];
 
     environment.systemPackages = [ pkgs.git gitlab-rake gitlab-rails cfg.packages.gitlab-shell ];