[SERVER-18877] Allow MongoRunner.runMongod Take In Environment Variables Created: 08/Jun/15 Updated: 29/Aug/16 Resolved: 03/May/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Shell, Testing Infrastructure |
| Affects Version/s: | None |
| Fix Version/s: | 3.3.6 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Robert Guo (Inactive) | Assignee: | Spencer Jackson |
| Resolution: | Done | Votes: | 0 |
| Labels: | 32qa | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||
| Sprint: | Security 6 07/17/15, Security 7 08/10/15, Security 12 (04/01/16), Security 13 (04/22/16), Security 14 (05/13/16) | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
Currently it's possible to set environment variables when starting a mongod from the mongo shell in the following fashion.
MongoRunner.runMongod should be able to take in environment variables as options and format it as environment variables to _startMongoProgram. This would enable shardingtest, replsettest and possibly other higher-level abstractions that use runMongod to also take in environment variables in their options. |
| Comments |
| Comment by Githook User [ 03/May/16 ] | |
|
Author: {u'username': u'spencerjackson', u'name': u'Spencer Jackson', u'email': u'spencer.jackson@mongodb.com'}Message: | |
| Comment by Kevin Pulo [ 02/Mar/16 ] | |
|
Another way of fixing this problem would be if | |
| Comment by Robert Guo (Inactive) [ 09/Jun/15 ] | |
|
Thanks for the tip kevin.pulo@10gen.com. This should work great! | |
| Comment by Kevin Pulo [ 09/Jun/15 ] | |
|
A workaround for the current _startMongoProgram is to use the POSIX env utility, eg.
Doesn't help for non-POSIX systems like Windows though. | |
| Comment by Robert Guo (Inactive) [ 08/Jun/15 ] | |
|
schwerin Set by the shell on the runner. I modified the description to clarify. | |
| Comment by Andy Schwerin [ 08/Jun/15 ] | |
|
Environment variables from the shell's environment, or set by the shell on the runner? |