updated to use os.environ