Added environment variable support