All command line option flags can be coded into a file, mongorc.js (https://docs.mongodb.com/manual/reference/program/mongo/#files). When you run the mongo command, this file is parsed unless you include the command line switch mongo --norc. There are two primary locations for this file; the user home directory, or the operating system's /etc directory:
Here ...