Add documentation about environment attribute
Only generate environment option if an environment is specified