CI fixes and refactoring.