From 66ac16681a8c36c1de10661d598b2cd2dff8065c Mon Sep 17 00:00:00 2001 From: wangjian Date: Tue, 30 Jul 2024 20:55:49 +0800 Subject: [PATCH 1/2] add kibana install --- playbook/host-standalone | 2 +- playbook/standalone.yml | 24 +++++++++++++++++++++++- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/playbook/host-standalone b/playbook/host-standalone index bd870b9..5cf0810 100644 --- a/playbook/host-standalone +++ b/playbook/host-standalone @@ -1,2 +1,2 @@ [standalone] -0.0.0.0 +10.41.160.164 diff --git a/playbook/standalone.yml b/playbook/standalone.yml index 9b0131d..85da67c 100644 --- a/playbook/standalone.yml +++ b/playbook/standalone.yml @@ -46,4 +46,26 @@ line: '-Xmx4g' backrefs: yes - name: start elasticsearch - shell: nohup /opt/elasticsearch-7.17.16/bin/elasticsearch -d & \ No newline at end of file + shell: nohup /opt/elasticsearch-7.17.16/bin/elasticsearch -d & + - name: get kibana from official website + shell: wget https://artifacts.elastic.co/downloads/kibana/kibana-7.17.16-linux-x86_64.tar.gz --no-check-certificate + args: + chdir: /root/ + when: arch == x86_64 + - name: unzip tar.gz + shell: tar -xzvf kibana.17.16-linux-x86_64.tar.gz -C /opt + args: + chdir: /root/ + when: arch == x86_64 + - name: get elasticsearch from official website + shell: wget https://artifacts.elastic.co/downloads/kibana/kibana-7.17.16-linux-aarch64.tar.gz --no-check-certificate + args: + chdir: /root/ + when: arch == aarch64 + - name: unzip tar.gz + shell: tar -xzvf kibana-7.17.16-linux-aarch64.tar.gz -C /opt + args: + chdir: /root/ + when: arch == aarch64 + - name: start kibana + shell: nohup /opt/kibana.17.16/bin/kibana & \ No newline at end of file -- Gitee From f145123f3a5e89ef2f94fab78bdeeca0910dab31 Mon Sep 17 00:00:00 2001 From: wangjian Date: Thu, 1 Aug 2024 11:03:33 +0800 Subject: [PATCH 2/2] fix some bugs --- playbook/standalone.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/playbook/standalone.yml b/playbook/standalone.yml index 85da67c..f0889e8 100644 --- a/playbook/standalone.yml +++ b/playbook/standalone.yml @@ -29,10 +29,10 @@ args: chdir: /root/ when: arch == aarch64 - - name: add elk user - shell: groupadd elk && useradd elk -g elk + - name: add elastic user + shell: groupadd elastic && useradd elastic -g elastic - name: chown /opt/elasticsearch-7.17.16/ - shell: chown -R elk:elk /opt/elasticsearch-7.17.16/ + shell: chown -R elastic:elastic /opt/elasticsearch-7.17.16/ - name: change jvms lineinfile: path: /opt/elasticsearch-7.17.16/config/jvm.options @@ -53,7 +53,7 @@ chdir: /root/ when: arch == x86_64 - name: unzip tar.gz - shell: tar -xzvf kibana.17.16-linux-x86_64.tar.gz -C /opt + shell: tar -xzvf kibana-7.17.16-linux-x86_64.tar.gz -C /opt args: chdir: /root/ when: arch == x86_64 @@ -68,4 +68,4 @@ chdir: /root/ when: arch == aarch64 - name: start kibana - shell: nohup /opt/kibana.17.16/bin/kibana & \ No newline at end of file + shell: nohup /opt/kibana-7.17.16/bin/kibana --allow-root & -- Gitee