Просмотр исходного кода

Added a sample lighttpd configuration for basic authentication

Robin Clarke 12 лет назад
Родитель
Сommit
9cd3fcf314
1 измененных файлов с 40 добавлено и 0 удалено
  1. 40 0
      sample/lighttpd_basic.conf

+ 40 - 0
sample/lighttpd_basic.conf

@@ -0,0 +1,40 @@
+$HTTP["host"] =~ "kibana" {
+
+    server.document-root = "/var/www/kibana/src"
+    auth.backend = "plain"
+    auth.backend.plain.userfile = "/etc/lighttpd/kibanapassword"
+
+    index-file.names            = ( "index.html", "index.htm" )
+
+    auth.require = ( "/" => (
+            "method"    => "basic",
+            "realm"     => "Password Protected",
+            "require"   => "valid-user"
+            )
+        )
+
+    $HTTP["url"] =~ "^/kibana-int/temp.*$" {
+        proxy.balance = "hash"
+        proxy.server = ( "" => ( ( "host" => "127.0.0.1", "port" => "9200" ) ) )
+    }
+    $HTTP["url"] =~ "^/kibana-int/dashboard/.*$" {
+        proxy.balance = "hash"
+        proxy.server = ( "" => ( ( "host" => "127.0.0.1", "port" => "9200" ) ) )
+    }
+    $HTTP["url"] =~ "^/_mappings$" {
+        proxy.balance = "hash"
+        proxy.server = ( "" => ( ( "host" => "127.0.0.1", "port" => "9200" ) ) )
+    }
+    $HTTP["url"] =~ "^/_search$" {
+        proxy.balance = "hash"
+        proxy.server = ( "" => ( ( "host" => "127.0.0.1", "port" => "9200" ) ) )
+    }
+    $HTTP["url"] =~ "^/_nodes$" {
+        proxy.balance = "hash"
+        proxy.server = ( "" => ( ( "host" => "127.0.0.1", "port" => "9200" ) ) )
+    }
+    $HTTP["url"] =~ "^/_aliases$" {
+        proxy.balance = "hash"
+        proxy.server = ( "" => ( ( "host" => "127.0.0.1", "port" => "9200" ) ) )
+    }
+}