Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Ant_Devops
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
mayi-operation
Ant_Devops
Commits
11f1e1c3
Commit
11f1e1c3
authored
Feb 21, 2019
by
ChongmingDu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
elk mod
parent
dda718b4
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
51 additions
and
0 deletions
+51
-0
roles/elk/files/elk.sh
+42
-0
roles/elk/tasks/main.yml
+9
-0
No files found.
roles/elk/files/elk.sh
0 → 100644
View file @
11f1e1c3
#!/bin/bash
yum
-y
install epel-release
yum
-y
install python-pip
pip install docker-compose
echo
"vm.max_map_count = 262144"
>
/etc/sysctl.conf
#install elasticsearch
# rpm --import https://artifacts.elastic.co/GPG-KEY-elasticsearch
# sudo yum install elasticsearch
# systemctl start elasticsearch.service
# systemctl enalbe elasticsearch.service
#bulid docker compose
cat
<<
EOF
>docker-compose.yml
version: '2.2'
services:
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:5.6.12
environment:
discovery.type: single-node
stdin_open: true
tty: true
volumes:
- ./es_data:/
ports:
- 9200:9200/tcp
labels:
io.rancher.container.pull_image: always
kibana:
image: docker.elastic.co/kibana/kibana:5.6.12
environment:
ELASTICSEARCH_URL: http://elasticsearch:9200
stdin_open: true
tty: true
links:
- elasticsearch:elasticsearch
ports:
- 5601:5601/tcp
labels:
io.rancher.container.pull_image: always
EOF
docker-compose up &
\ No newline at end of file
roles/elk/tasks/main.yml
0 → 100644
View file @
11f1e1c3
---
-
name
:
"
copy
elk
shell"
copy
:
src
:
elk.sh
dest
:
/root/elk.sh
-
name
:
"
run
elk
shell
script"
shell
:
/bin/bash /root/elk.sh
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment