environment var setup and db plugin