From faf71d98f4228a24d2b1a2afb2c2b33dd614cb45 Mon Sep 17 00:00:00 2001 From: Phrozyn Date: Tue, 23 Aug 2016 10:58:18 -0500 Subject: [PATCH] Adding config and systemdfiles dir with mongod and kibana. --- config/mongod.conf | 45 +++++++++++++++++++++++++++++++++++++ "systemdfiles/\\" | 17 ++++++++++++++ systemdfiles/kibana.service | 16 +++++++++++++ systemdfiles/mongod.service | 17 ++++++++++++++ 4 files changed, 95 insertions(+) create mode 100644 config/mongod.conf create mode 100644 "systemdfiles/\\" create mode 100644 systemdfiles/kibana.service create mode 100644 systemdfiles/mongod.service diff --git a/config/mongod.conf b/config/mongod.conf new file mode 100644 index 00000000..b4fb05a7 --- /dev/null +++ b/config/mongod.conf @@ -0,0 +1,45 @@ +# mongod.conf + +# for documentation of all options, see: +# http://docs.mongodb.org/manual/reference/configuration-options/ + +# where to write logging data. +systemLog: + destination: file + logAppend: true + path: /opt/mozdef/envs/mozdef/logs/meteor-mongo.log + +# Where and how to store data. +storage: + dbPath: /opt/mozdef/envs/mongo/db + journal: + enabled: true + mmapv1: + smallFiles: true +# wiredTiger: + +# how the process runs +processManagement: + fork: true # fork and run in background + pidFilePath: /var/run/mozdefdb/mozdefdb.pid # location of pidfile + +# network interfaces +net: + port: 3002 + bindIp: 127.0.0.1 # Listen to local interface only, comment to listen on all interfaces. + + +#security: + +#operationProfiling: + +replication: + oplogSizeMB: 8 + +#sharding: + +## Enterprise-Only Options + +#auditLog: + +#snmp: diff --git "a/systemdfiles/\\" "b/systemdfiles/\\" new file mode 100644 index 00000000..a0633cec --- /dev/null +++ "b/systemdfiles/\\" @@ -0,0 +1,17 @@ +[Unit] +Description=MongoDB Database Service +After=network.target + +[Service] +Type=forking +PIDFile=/var/run/mozdefdb/mozdefdb.pid +ExecStart=/usr/bin/mongod --config /etc/mongod.conf +ExecReload=/bin/kill -HUP $MAINPID +#Restart=always +User=mozdef +Group=mozdef +StandardOutput=syslog +StandardError=syslog + +[Install] +WantedBy=multi-user.target diff --git a/systemdfiles/kibana.service b/systemdfiles/kibana.service new file mode 100644 index 00000000..e8be9689 --- /dev/null +++ b/systemdfiles/kibana.service @@ -0,0 +1,16 @@ +[Unit] +Description=Kibana +Requires=elasticsearch.service + +[Service] +ExecStart=/opt/mozdef/envs/kibana/bin/kibana +Restart=always +StandardOutput=syslog +StandardError=syslog +SyslogIdentifier=kibana4 +User=mozdef +Group=mozdef +SuccessExitStatus=143 + +[Install] +WantedBy=multi-user.target diff --git a/systemdfiles/mongod.service b/systemdfiles/mongod.service new file mode 100644 index 00000000..a0633cec --- /dev/null +++ b/systemdfiles/mongod.service @@ -0,0 +1,17 @@ +[Unit] +Description=MongoDB Database Service +After=network.target + +[Service] +Type=forking +PIDFile=/var/run/mozdefdb/mozdefdb.pid +ExecStart=/usr/bin/mongod --config /etc/mongod.conf +ExecReload=/bin/kill -HUP $MAINPID +#Restart=always +User=mozdef +Group=mozdef +StandardOutput=syslog +StandardError=syslog + +[Install] +WantedBy=multi-user.target