diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml
index bda84e16..e566d941 100644
--- a/bitbucket-pipelines.yml
+++ b/bitbucket-pipelines.yml
@@ -15,24 +15,20 @@ pipelines:
           caches:
             - node
             - maven
+            - docker
           script:
             # Compile sources ...
             - curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.36.0/install.sh | bash
             - . $HOME/.nvm/nvm.sh && nvm install node
             - mvn -B verify --file pom.xml
+            # Publish to docker repo ...
+            - docker login --username $DOCKER_USERNAME --password $DOCKER_PASSWORD
+            - docker build -t veigap/wisemapping:latest -f distribution/Dockerfile wise-webapp/target/
           after-script:
             # Collect checkstyle results, if any, and convert to Bitbucket Code Insights.
             - pipe: atlassian/checkstyle-report:0.3.0
-      - step:
-          name: Docker publish
-          script:
-            - echo $DOCKER_USERNAME
-            - docker login --username $DOCKER_USERNAME --password $DOCKER_PASSWORD
-            - docker build -t veigap/wisemapping:latest -f distribution/Dockerfile wise-webapp/target/
           services:
             - docker
-          caches:
-            - docker
       - step:
           name: Security Scan
           script: