Refactoring of docker scripts