diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8f689f8366412e4a0ee11df863b49cb8f104a543..800b68081e7cc2fac1155de231628ecb55244481 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -75,6 +75,9 @@ pages:
 
 dist:
   stage: deploy
+  variables:
+    # Force a full clone to make version machinery work.
+    GIT_STRATEGY: clone
   only:
     - /^release\/[0-9]+\.[0-9]+\.[0-9]+.*$/
   script: