Permalink
Browse files

nixos/gitea: add mysql socket authentication as an option

  • Loading branch information...
aanderse committed Nov 6, 2018
1 parent 0bbb6f4 commit 3ed52c78047bcc4b74d34e0cee179bb708aebdc0
Showing with 8 additions and 1 deletion.
  1. +8 −1 nixos/modules/services/misc/gitea.nix
@@ -15,7 +15,7 @@ let
[database]
DB_TYPE = ${cfg.database.type}
HOST = ${cfg.database.host}:${toString cfg.database.port}
HOST = ${if cfg.database.socket != null then cfg.database.socket else cfg.database.host + ":" + toString cfg.database.port}
NAME = ${cfg.database.name}
USER = ${cfg.database.user}
PASSWD = #dbpass#
@@ -149,6 +149,13 @@ in
'';
};
socket = mkOption {
type = types.nullOr types.path;
default = null;
example = "/run/mysqld/mysqld.sock";
description = "Path to the unix socket file to use for authentication.";
};
path = mkOption {
type = types.str;
default = "${cfg.stateDir}/data/gitea.db";

0 comments on commit 3ed52c7

Please sign in to comment.