fixes issues for build-image environment