-
Notifications
You must be signed in to change notification settings - Fork 4
/
manifest.jps
67 lines (58 loc) · 3.09 KB
/
manifest.jps
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
type: install
name: GrayLog
logo: images/graylog-logo.png
homepage: https://www.graylog.org/
baseUrl: https://raw.githubusercontent.com/jelastic-jps/graylog/master/
description: |
Graylog is a centralized log management solution built to open standards for capturing, storing, and enabling real-time analysis.
Single server installation.
skipNodeEmails: true
categories:
- apps/dev-and-admin-tools
globals:
GRAYLOG_PASSWD: ${fn.password(12)}
SECRET: ${fn.password(96)}
nodes:
- nodeType: centos7
cloudlets: 32
extip: true
onInstall:
- installCommon
- installMongo
- installElastic
- installGraylog
actions:
installCommon:
- cmd [centos7]: |-
yum install epel-release -y >/dev/null 2>&1
yum install net-tools pwgen java-1.8.0-openjdk-headless.x86_64 -y >/dev/null 2>&1
installMongo:
- cmd [centos7]: |-
wget -qO /etc/yum.repos.d/mongodb-org.repo http://dot.jelastic.com/download/team.operations/graylog/mongodb-org.repo
yum install mongodb-org -y >/dev/null 2>&1
systemctl daemon-reload ; systemctl enable mongod.service ; systemctl start mongod.service
installElastic:
- cmd [centos7]: |-
wget -qO /etc/yum.repos.d/elasticsearch.repo http://dot.jelastic.com/download/team.operations/graylog/elasticsearch.repo
rpm --import https://artifacts.elastic.co/GPG-KEY-elasticsearch
yum install elasticsearch-oss -y >/dev/null 2>&1
sed 's/#cluster.name: my-application/cluster.name: graylog/' -i /etc/elasticsearch/elasticsearch.yml
sed '/cluster.name: graylog/a action.auto_create_index: false' -i /etc/elasticsearch/elasticsearch.yml
systemctl daemon-reload ; systemctl enable elasticsearch.service ; systemctl restart elasticsearch.service
installGraylog:
- cmd [centos7]: |-
rpm -Uvh https://packages.graylog2.org/repo/packages/graylog-3.2-repository_latest.rpm >/dev/null 2>&1
yum install graylog-server -y >/dev/null 2>&1
sed "s/password_secret =/password_secret = ${globals.SECRET}/" -i /etc/graylog/server/server.conf
PASSWORD_SHA2=$(echo -n ${globals.GRAYLOG_PASSWD} | sha256sum | cut -d" " -f1) ; sed "s/root_password_sha2 =/root_password_sha2 = ${PASSWORD_SHA2}/" -i /etc/graylog/server/server.conf
sed -e "/# Default:[[:space:]]127.0.0.1:9000/a http_bind_address = 0.0.0.0:9000" -i /etc/graylog/server/server.conf
sed -e "/#http_publish_uri/a http_publish_uri = http://${nodes.centos7.extips}:9000/" -i /etc/graylog/server/server.conf
sed -e "/allow_leading_wildcard_searches[[:space:]]*=[[:space:]]*false/allow_leading_wildcard_searches = true/" -i /etc/graylog/server/server.conf
systemctl daemon-reload ; systemctl enable graylog-server.service ; systemctl start graylog-server.service ; systemctl stop iptables ; systemctl restart graylog-server.service
success:
text: |
### Graylog
* **URL** [http://${nodes.centos7.extips}:9000](http://${nodes.centos7.extips}:9000)
* **Login:** admin
* **Password:** ${globals.GRAYLOG_PASSWD}
# https://docs.graylog.org/en/3.1/pages/installation/os/centos.html