Added migrations for resources. Added database config and environment variables