about summary refs log tree commit diff
path: root/tools/nixery/server/config/config.go
diff options
context:
space:
mode:
authorVincent Ambo <tazjin@google.com>2019-09-21T11·15+0100
committerVincent Ambo <github@tazj.in>2019-09-21T11·44+0100
commit64f74abc4df6676e3cd4c7f34210fd2aea433f16 (patch)
treefd213bf2f9e279cfab4a9bf98f5ee5866fd25837 /tools/nixery/server/config/config.go
parente4d03fdb17041ead530aa3e115f84988148a3b21 (diff)
feat: Add configuration option for popularity data URL
Diffstat (limited to 'tools/nixery/server/config/config.go')
-rw-r--r--tools/nixery/server/config/config.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/nixery/server/config/config.go b/tools/nixery/server/config/config.go
index ea1bb1ab4532..ac8820f23116 100644
--- a/tools/nixery/server/config/config.go
+++ b/tools/nixery/server/config/config.go
@@ -68,6 +68,7 @@ type Config struct {
 	Pkgs    PkgSource                 // Source for Nix package set
 	Timeout string                    // Timeout for a single Nix builder (seconds)
 	WebDir  string                    // Directory with static web assets
+	PopUrl  string                    // URL to the Nix package popularity count
 }
 
 func FromEnv() (*Config, error) {
@@ -83,5 +84,6 @@ func FromEnv() (*Config, error) {
 		Signing: signingOptsFromEnv(),
 		Timeout: getConfig("NIX_TIMEOUT", "Nix builder timeout", "60"),
 		WebDir:  getConfig("WEB_DIR", "Static web file dir", ""),
+		PopUrl:  os.Getenv("NIX_POPULARITY_URL"),
 	}, nil
 }