Partial fix for bug 1014837

Environment variables and ssh keys are expected to have unique names and an attempt to add a new environment variable or an ssh key with the same name ends up updating the existing variable or ssh key. However, on the broker/mongo, adding another variable or ssh key with the same name ended up creating another entry in the list. 

This fix would ensure that the broker/mongo and the node have the same behavior with regards to adding an environment variable or an ssh key.