mirror of
https://github.com/elastic/logstash.git
synced 2025-04-22 21:57:26 -04:00
This new command replace the old workflow of `pack`, `unpack` and the `install --local`, and wrap all the logic into one uniform way of installing plugins. The work is based on the flow developed for installing an x-pack inside Logstash, when you call prepare-offline-pack, the specified plugins and their dependencies will be packaged in a zip. And this zip can be installed with the same flow as the pack. Definition: Source Logstash: Where you run the prepare-offline-pack. Target Logstash: Where you install the offline package. PROS: - If you install a .gem in the source logstash, the .gem and his dependencies will be bundled. - The install flow doesn't need to have access to the internet. - Nothing special need to be setup in the target logstash environment. CONS: - The is one minor drawback, the plugins need to have their JARS bundled with them for this flow to work, this is currently the case for all the official plugins. - The source Logstash need to have access to the internet when you install plugins before packaging them. Usage examples: bin/logstash-plugin prepare-offline-pack logstash-input-beats bin/logstash-plugin prepare-offline-pack logstash-filter-jdbc logstash-input-beats bin/logstash-plugin prepare-offline-pack logstash-filter-* bin/logstash-plugin prepare-offline-pack logstash-filter-* logstash-input-beats How to install: bin/logstash-plugin install file:///tmp/logstash-offline-plugins-XXXX.zip Fixes #6404
24 lines
613 B
Bash
Executable file
24 lines
613 B
Bash
Executable file
#!/bin/sh
|
|
set -e
|
|
|
|
# Since we are using the system jruby, we need to make sure our jvm process
|
|
# uses at least 1g of memory, If we don't do this we can get OOM issues when
|
|
# installing gems. See https://github.com/elastic/logstash/issues/5179
|
|
export JRUBY_OPTS="-J-Xmx1g"
|
|
|
|
echo "Running integration tests from qa/integration"
|
|
if [[ ! -d "build" ]]; then
|
|
mkdir build
|
|
fi
|
|
rm -rf build/*
|
|
echo "Building logstash tar file in build/"
|
|
rake artifact:tar
|
|
cd build
|
|
echo "Extracting logstash tar file in build/"
|
|
tar xf *.tar.gz
|
|
|
|
cd ../qa/integration
|
|
# to install test dependencies
|
|
bundle install
|
|
# runs all tests
|
|
rspec
|