[dev-db/mongodb] for 6 migrate socket to /run and change logdir creation to tmpfiles

This commit is contained in:
2024-06-06 15:20:40 +02:00
parent 94ebf5ce48
commit 360db7b1ab
5 changed files with 77 additions and 16 deletions

View File

@@ -0,0 +1,36 @@
# !! IMPORTANT !!
#
# This file uses the YAML format as described in the documentation:
# http://docs.mongodb.org/manual/reference/configuration-options/
storage:
dbPath: "/var/lib/mongodb"
#engine: wiredTiger
systemLog:
destination: file
path: "/var/log/mongodb/mongodb.log"
quiet: true
logAppend: true
net:
port: 27017
bindIp: 127.0.0.1
unixDomainSocket:
pathPrefix: "/run/mongodb"
#ssl:
# mode: disabled
#security:
#keyFile:
#clusterAuthMode:
#replication:
#replSetName:
# Specifies one of the MongoDB parameters described here:
# http://docs.mongodb.org/manual/reference/parameters/
#
# You can specify multiple setParameter fields such as:
# setParameter: {enableTestCommands: 1}
#setParameter:

View File

@@ -1,10 +0,0 @@
[Unit]
Description=High-performance, schema-free document-oriented database
After=network.target
[Service]
User=mongodb
ExecStart=/usr/bin/mongod --quiet --config /etc/mongodb.conf
[Install]
WantedBy=multi-user.target

View File

@@ -0,0 +1,2 @@
d /var/log/mongodb 0750 mongodb mongodb -
d /run/mongodb 0750 mongodb mongodb -

View File

@@ -0,0 +1,32 @@
# !! IMPORTANT !!
#
# This file uses the YAML format as described in the documentation:
# http://docs.mongodb.org/manual/reference/configuration-options/
systemLog:
destination: file
path: "/var/log/mongodb/mongos.log"
quiet: true
logAppend: true
net:
port: 27017
bindIp: 127.0.0.1
unixDomainSocket:
pathPrefix: "/run/mongodb"
ssl:
mode: disabled
#security:
#keyFile:
#clusterAuthMode:
#sharding:
#configDB:
# Specifies one of the MongoDB parameters described here:
# http://docs.mongodb.org/manual/reference/parameters/
#
# You can specify multiple setParameter fields such as:
# setParameter: {enableTestCommands: 1}
#setParameter: