[MacPorts] #45803: mongodb @2.6.5_1: Run mongod instance with config file
#45803: mongodb @2.6.5_1: Run mongod instance with config file -------------------------+-------------------------------- Reporter: mark@… | Owner: macports-tickets@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.2 Keywords: | Port: mongodb -------------------------+-------------------------------- As indicated in the documentation, it is preferred to run the mongod instance via the config file, not command line parameters: http://docs.mongodb.org/manual/reference/program/mongod/#cmdoption--config I've attached a sample mongod.conf file that replicates the existing options - plus one SSL option now mongodb compiles with `--ssl` by default. I'm not sure how MacPorts handles default config files when installing or updating ports. I imagine that you would want to create `mongod.conf` if it doesn't exist, but name it `mongod-default.conf` if one does exist as to not overwrite user-defined parameters that might be needed for the instance to start. -- Ticket URL: <https://trac.macports.org/ticket/45803> MacPorts <https://www.macports.org/> Ports system for OS X
#45803: mongodb @2.6.5_1: Run mongod instance with config file --------------------------+-------------------------- Reporter: mark@… | Owner: ryandesign@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: Resolution: | Keywords: Port: mongodb | --------------------------+-------------------------- Changes (by mf2k@…): * owner: macports-tickets@… => ryandesign@… * cc: ryandesign@… (removed) * version: 2.3.2 => -- Ticket URL: <https://trac.macports.org/ticket/45803#comment:1> MacPorts <https://www.macports.org/> Ports system for OS X
#45803: mongodb @2.6.5_1: Run mongod instance with config file --------------------------+-------------------------- Reporter: mark@… | Owner: ryandesign@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: Resolution: | Keywords: Port: mongodb | --------------------------+-------------------------- Comment (by mark@…): Perhaps the port file could be changed to something like: {{{ startupitem.executable sudo -u ${mongouser} ${prefix}/bin/mongod --config ${prefix}/etc/mongodb/mongodb.conf post-activate { if {![file exists ${prefix}/etc/mongodb/mongod.conf]} { file copy ${prefix}/etc/mongodb/mongod.conf.sample \ ${prefix}/etc/mongodb/mongod.conf } } }}} The above attached file replicates the existing startup item (with SSL added). Moving to config file would make it quite a bit easier for those of us who need to add [http://docs.mongodb.org/manual/reference /configuration-options/ other startup options]. -- Ticket URL: <https://trac.macports.org/ticket/45803#comment:2> MacPorts <https://www.macports.org/> Ports system for OS X
#45803: mongodb @2.6.5_1: Run mongod instance with config file --------------------------+-------------------------- Reporter: mark@… | Owner: ryandesign@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: Resolution: | Keywords: Port: mongodb | --------------------------+-------------------------- Comment (by mark@…): Version 3 has the same config structure, so the above change should still work. -- Ticket URL: <https://trac.macports.org/ticket/45803#comment:3> MacPorts <https://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts