1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Kibanaだとダッシュボードをiframeで表示するのが簡単だった

Last updated at Posted at 2021-06-06

Kibanaに接続

docker-compose.yml
version: "3"

services:

  elasticsearch:
    image: docker.elastic.co/elasticsearch/elasticsearch:7.13.1
    environment:
      - discovery.type=single-node
      - cluster.name=docker-cluster
      - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
    ports:
      - 9200:9200
    volumes:
      - es-data:/usr/share/elasticsearch/data

  kibana:
    image: docker.elastic.co/kibana/kibana:7.13.1
    ports:
      - 5601:5601
    environment:
      - "I18N_LOCALE=ja-JP"

volumes:
  es-data:

設定

1.PNG

  • サンプルデータ - データの追加

2.png

  • データを表示

3.png

4.png

  • iFrameコードをコピー

5.png

iframeを仕込む

以下のような形式になる。

<iframe src="http://host:5601/app/dashboards#/view/7adfa750-4c81-11e8-b3d7-01146121b73d?embed=true&_g=(filters%3A!()%2CrefreshInterval%3A(pause%3A!f%2Cvalue%3A900000)%2Ctime%3A(from%3Anow-24h%2Cto%3Anow))" height="600" width="800"></iframe>

  • index.html の作成

6.PNG

  • 表示できた。

7-index.PNG

  • 実際はNginxなどでbasic認証などをではさんで接続が良いと思う。

データの投入

  • 開発ツール からjsonの投入が容易

dev-tool2.png

その他

Google チャートも簡単かも

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?