make sure runtime config is writte before migrate_db