diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 27ef9137073be22c4457ffe89c14bec188a8ffd5..4d873a9f3a6ee3e50ad3208fab7d0b197dddfc97 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -150,7 +150,7 @@ pages:
   stage: deploy
   needs:
     - 'Check Code'
-  image: python:latest
+  image: python:3.12
   artifacts:
     paths:
       - public
diff --git a/includes/include.drupalci.main.yml b/includes/include.drupalci.main.yml
index 969c275b356eca21684dddb10eb401355819b4cf..a0de0c4ebd32342890672583b2ae9457fd1a2e1f 100644
--- a/includes/include.drupalci.main.yml
+++ b/includes/include.drupalci.main.yml
@@ -515,7 +515,7 @@ composer (next major):
 
 pages:
   stage: build
-  image: python:latest
+  image: python:3.12
   script:
     - pip install mkdocs-material
     - pwd && ls -l logo* && ls -l docs/logo* || true