mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-04-15 07:57:56 +00:00
nixos/jenkins-job-builder: better defaults for accessUser/accessTokenFile
The new defaults allows jenkins-job-builder to reload the configuration out-of-the-box, whereas the previous defaults required users to manually reload/restart jenkins, or configure accessUser/accessTokenFile themselves. (If `extraJavaOptions = [ "-Djenkins.install.runSetupWizard=false" ]` then the initial admin user is *not* created and you have to use JCasC or something else to bootstrap.)
This commit is contained in:
parent
a8a8a9e2e7
commit
fcf81f91a3
@ -30,7 +30,7 @@ in {
|
||||
};
|
||||
|
||||
accessUser = mkOption {
|
||||
default = "";
|
||||
default = "admin";
|
||||
type = types.str;
|
||||
description = lib.mdDoc ''
|
||||
User id in Jenkins used to reload config.
|
||||
@ -48,7 +48,8 @@ in {
|
||||
};
|
||||
|
||||
accessTokenFile = mkOption {
|
||||
default = "";
|
||||
default = "${config.services.jenkins.home}/secrets/initialAdminPassword";
|
||||
defaultText = literalExpression ''"''${config.services.jenkins.home}/secrets/initialAdminPassword"'';
|
||||
type = types.str;
|
||||
example = "/run/keys/jenkins-job-builder-access-token";
|
||||
description = lib.mdDoc ''
|
||||
|
@ -18,8 +18,6 @@ import ./make-test-python.nix ({ pkgs, ...} : {
|
||||
enable = true;
|
||||
jobBuilder = {
|
||||
enable = true;
|
||||
accessUser = "admin";
|
||||
accessTokenFile = "/var/lib/jenkins/secrets/initialAdminPassword";
|
||||
nixJobs = [
|
||||
{ job = {
|
||||
name = "job-1";
|
||||
|
Loading…
Reference in New Issue
Block a user