kibana 6.4.1
This commit is contained in:
parent
2ebdf08ce8
commit
b4e7f4a4fd
2 changed files with 19 additions and 15 deletions
|
@ -1,13 +1,9 @@
|
|||
require "language/node"
|
||||
|
||||
class Kibana < Formula
|
||||
desc "Analytics and search dashboard for Elasticsearch"
|
||||
homepage "https://www.elastic.co/products/kibana"
|
||||
# Pinned at 6.2.x because of a licencing issue
|
||||
# See: https://github.com/Homebrew/homebrew-core/pull/28995
|
||||
url "https://github.com/elastic/kibana.git",
|
||||
:tag => "v6.2.4",
|
||||
:revision => "ee501cfd9c1281cfbd6948e1c5f80dc9356ee56f"
|
||||
:tag => "v6.4.1",
|
||||
:revision => "2872c74872c54d91e3e00b67c7bbc61659df0ba7"
|
||||
head "https://github.com/elastic/kibana.git"
|
||||
|
||||
bottle do
|
||||
|
@ -17,9 +13,13 @@ class Kibana < Formula
|
|||
end
|
||||
|
||||
resource "node" do
|
||||
url "https://github.com/nodejs/node.git",
|
||||
:tag => "v6.14.0",
|
||||
:revision => "2c93af2da3b696e2389ba46608efb9bdffd8badd"
|
||||
url "https://nodejs.org/dist/v8.11.4/node-v8.11.4.tar.xz"
|
||||
sha256 "fbce7de6d96b0bcb0db0bf77f0e6ea999b6755e6930568aedaab06847552a609"
|
||||
end
|
||||
|
||||
resource "yarn" do
|
||||
url "https://yarnpkg.com/downloads/1.9.4/yarn-v1.9.4.tar.gz"
|
||||
sha256 "7667eb715077b4bad8e2a832e7084e0e6f1ba54d7280dc573c8f7031a7fb093e"
|
||||
end
|
||||
|
||||
def install
|
||||
|
@ -28,18 +28,22 @@ class Kibana < Formula
|
|||
system "make", "install"
|
||||
end
|
||||
|
||||
# do not build packages for other platforms
|
||||
inreplace buildpath/"tasks/config/platforms.js", /('(linux-x64|windows-x64)',?(?!;))/, "// \\1"
|
||||
# remove non open source files
|
||||
rm_rf "x-pack"
|
||||
|
||||
# trick the build into thinking we've already downloaded the Node.js binary
|
||||
mkdir_p buildpath/".node_binaries/#{resource("node").version}/darwin-x64"
|
||||
|
||||
# set npm env and fix cache edge case (https://github.com/Homebrew/brew/pull/37#issuecomment-208840366)
|
||||
# run yarn against the bundled node version and not our node formula
|
||||
(buildpath/"yarn").install resource("yarn")
|
||||
(buildpath/".brew_home/.yarnrc").write "build-from-source true\n"
|
||||
ENV.prepend_path "PATH", buildpath/"yarn/bin"
|
||||
ENV.prepend_path "PATH", prefix/"libexec/node/bin"
|
||||
system "npm", "install", "-ddd", "--build-from-source", "--#{Language::Node.npm_cache_config}"
|
||||
system "npm", "run", "build", "--", "--release", "--skip-os-packages", "--skip-archives"
|
||||
system "yarn", "kbn", "bootstrap"
|
||||
system "yarn", "build", "--oss", "--release", "--skip-os-packages", "--skip-archives"
|
||||
|
||||
prefix.install Dir["build/kibana-#{version}-darwin-x86_64/{bin,config,node_modules,optimize,package.json,src,ui_framework,webpackShims}"]
|
||||
prefix.install Dir["build/oss/kibana-#{version}-darwin-x86_64/{bin,config,node_modules,optimize,package.json,src,ui_framework,webpackShims}"]
|
||||
mv "licenses/APACHE-LICENSE-2.0.txt", "LICENSE.txt" # install OSS license
|
||||
|
||||
inreplace "#{bin}/kibana", %r{/node/bin/node}, "/libexec/node/bin/node"
|
||||
inreplace "#{bin}/kibana-plugin", %r{/node/bin/node}, "/libexec/node/bin/node"
|
||||
|
|
Loading…
Reference in a new issue