diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8d3f05f7d61c7a3967d149880a72cea5a9e4de9e..2690cce43ec0421c88db4568eac0a24577a2a776 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -64,9 +64,16 @@ pre vars:
     reports:
       dotenv: variables.env
   script:
-  # Create the TF_VAR_env variable
-  - echo "TF_VAR_env=$(echo $CI_COMMIT_REF_SLUG | cut -c 1-7)-$(echo $CI_COMMIT_SHA | cut -c 1-7)" >> variables.env
-  - cat variables.env
+    # Create the TF_VAR_env variable
+    - echo "TF_VAR_env=$(echo $CI_COMMIT_REF_SLUG | cut -c 1-7)-$(echo $CI_COMMIT_SHA | cut -c 1-7)" >> variables.env
+    - cat variables.env
+  retry:
+    max: 2
+    when:
+      - unknown_failure
+      - stuck_or_timeout_failure
+      - runner_system_failure
+
 
 #-----------------------------------------------------------------------------------------------------------------------