diff --git a/.gitlab-ci-docs.yml b/.gitlab-ci-docs.yml
index 42ec1a19cd02b33b9dde462258e6a5ca30ea764f..bb0617f8a0653963084453fa92d3ce1ca35eab42 100644
--- a/.gitlab-ci-docs.yml
+++ b/.gitlab-ci-docs.yml
@@ -2,9 +2,12 @@
 
 docs:
   stage: build
-  image: python:3.7-alpine
+  image: python:3.7-slim
 
   before_script:
+    - apt-get update
+    - apt-get install -y --no-install-recommends gcc
+
     # TODO: we should consider also version locking these packages:
     #  ++ everything will work in the future
     #  -- we won't see any future improvements of the mkdocs and mkdocs-material packages