Added configfile support and sample config