added figaro env variable support and mail configurations