From ced9e83732a6c077b51797da691fe95d0b379304 Mon Sep 17 00:00:00 2001 From: Oliver Charles Date: Thu, 20 Nov 2014 15:27:06 +0000 Subject: [PATCH] OpenTSDB should create its schema on start up --- nixos/modules/services/databases/opentsdb.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/nixos/modules/services/databases/opentsdb.nix b/nixos/modules/services/databases/opentsdb.nix index dce2d1936418..fc037b58c0e0 100644 --- a/nixos/modules/services/databases/opentsdb.nix +++ b/nixos/modules/services/databases/opentsdb.nix @@ -74,6 +74,11 @@ in { environment.JAVA_HOME = "${pkgs.jre}"; path = [ pkgs.gnuplot ]; + preStart = + '' + COMPRESSION=NONE HBASE_HOME=${config.services.hbase.package} ${cfg.package}/share/opentsdb/tools/create_table.sh + ''; + serviceConfig = { PermissionsStartOnly = true; User = cfg.user;