forked from lix-project/hydra
hydra-module.nix: Fix setting the logo
This commit is contained in:
parent
243b05f1e7
commit
d710c1e443
|
@ -19,14 +19,14 @@ let
|
||||||
};
|
};
|
||||||
|
|
||||||
serverEnv = env //
|
serverEnv = env //
|
||||||
{ HYDRA_LOGO = if cfg.logo != null then cfg.logo else "";
|
{ HYDRA_TRACKER = cfg.tracker;
|
||||||
HYDRA_TRACKER = cfg.tracker;
|
|
||||||
} // (optionalAttrs cfg.debugServer { DBIC_TRACE = 1; });
|
} // (optionalAttrs cfg.debugServer { DBIC_TRACE = 1; });
|
||||||
in
|
in
|
||||||
|
|
||||||
{
|
{
|
||||||
###### interface
|
###### interface
|
||||||
options = {
|
options = {
|
||||||
|
|
||||||
services.hydra = rec {
|
services.hydra = rec {
|
||||||
|
|
||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
|
@ -109,7 +109,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
logo = mkOption {
|
logo = mkOption {
|
||||||
type = types.nullOr types.str;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
description = ''
|
description = ''
|
||||||
File name of an alternate logo to be displayed on the web pages.
|
File name of an alternate logo to be displayed on the web pages.
|
||||||
|
@ -135,12 +135,16 @@ in
|
||||||
###### implementation
|
###### implementation
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
services.hydra.extraConfig =
|
services.hydra.extraConfig =
|
||||||
''
|
''
|
||||||
using_frontend_proxy 1
|
using_frontend_proxy 1
|
||||||
base_uri ${cfg.hydraURL}
|
base_uri ${cfg.hydraURL}
|
||||||
notification_sender ${cfg.notificationSender}
|
notification_sender ${cfg.notificationSender}
|
||||||
max_servers 25
|
max_servers 25
|
||||||
|
${optionalString (cfg.logo != null) ''
|
||||||
|
hydra_logo ${cfg.logo}
|
||||||
|
''}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
environment.systemPackages = [ cfg.package ];
|
environment.systemPackages = [ cfg.package ];
|
||||||
|
|
Loading…
Reference in a new issue