Skip to content

Commit

Permalink
Rewrite import_dashboards.sh script in go (#2155)
Browse files Browse the repository at this point in the history
* Generate Kibana index pattern from etc/kibana/fields.yml

The format of each field can be specified in fields.yml using the `format` option.

Generate Kibana index pattern for all the elastic beats by running `make update`

* Re-write the import script in golang, to have one script for windows and unix systems instead of two scripts (bash
+powershell).

The script imports the dashboards together with visualizations, searches and index pattern for a Beat in Elasticsearch.
The script is added to the Beat package.

* fix makefile

* address comments
  • Loading branch information
monicasarbu authored and tsg committed Aug 17, 2016
1 parent 3ac6b8d commit 5a5c5a5
Show file tree
Hide file tree
Showing 7 changed files with 589 additions and 20 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ https://github.com/elastic/beats/compare/v5.0.0-alpha5...master[Check the HEAD d
- Add kafka message timestamp if at least version 0.10 is configured. {pull}2190[2190]
- Enhance contains condition to work on fields that are arrays of strings. {issue}2237[2237]
- Lookup the configuration file relative to the `-path.config` CLI flag. {pull}2245[2245]
- Re-write import_dashboards.sh in Golang. {pull}2155[2155]

*Metricbeat*

Expand Down
5 changes: 3 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

BUILD_DIR=build
COVERAGE_DIR=${BUILD_DIR}/coverage
BEATS=packetbeat filebeat winlogbeat metricbeat
Expand Down Expand Up @@ -64,8 +65,8 @@ simplify:
# Collects all dashboards and generates dashboard folder for https://github.com/elastic/beats-dashboards/tree/master/dashboards
.PHONY: beats-dashboards
beats-dashboards:
mkdir -p build
$(foreach var,$(PROJECTS),cp -r $(var)/etc/kibana/ build/dashboards || exit 1;)
mkdir -p build/dashboards
$(foreach var,$(BEATS),cp -r $(var)/etc/kibana/ build/dashboards/$(var) || exit 1;)

# Builds the documents for each beat
.PHONY: docs
Expand Down
1 change: 1 addition & 0 deletions libbeat/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ _output
/docs/html_docs
.vagrant
build
/dashboards/import_dashboards

# Architecture specific extensions/prefixes
*.[568vq]
Expand Down
Loading

0 comments on commit 5a5c5a5

Please sign in to comment.