diff --git a/mongodb-org/templates/mongod-3.4.conf.j2 b/mongodb-org/templates/mongod-3.4.conf.j2 index 57bde409..c07915e2 100644 --- a/mongodb-org/templates/mongod-3.4.conf.j2 +++ b/mongodb-org/templates/mongod-3.4.conf.j2 @@ -16,7 +16,7 @@ storage: # where to write logging data. systemLog: destination: {{ mongodb_systemlog_destination }} - path: {{ mongodb_logpath }} +{% if mongodb_logrotate_management %} {% if not mongodb_systemlog_external_logrotate %} logRotate: rename logAppend: false @@ -24,10 +24,16 @@ systemLog: logRotate: reopen logAppend: true {% endif %} +{% else %} + logAppend: true +{% endif %} + path: {{ mongodb_logpath }} # network information net: port: {{ mongodb_tcp_port }} +{% if mongodb_bind %} bindIp: {{ mongo_bind_ip }} +{% endif %} {% if mongodb_ssl_enabled %} ssl: mode: {{ mongodb_ssl_mode }} @@ -39,12 +45,13 @@ net: #processManagement: -{%if mongodb_cluster_enabled %} security: - keyFile: /data/mongo_home/dev-d4science-keyfile + keyFile: {{ mongodb_replica_keyfile }} + +{%if mongodb_cluster_enabled %} replication: - oplogSizeMB: 2000 + oplogSizeMB: {{ mongodb_oplog_size }} replSetName: {{ mongodb_replicaset }} {% endif %}