Add support for secrets file, misc moves/changes