diff --git a/9.2.5.Dockerfile b/9.2.5.Dockerfile
index 79f4f8099309e8be20a1d2979457a3f450586b72..4026842a92e09e0b3e49188c29c3fdf37c260457 100644
--- a/9.2.5.Dockerfile
+++ b/9.2.5.Dockerfile
@@ -58,7 +58,7 @@ RUN cd /tmp \
   && make binary-dist \
   && cabal update \
   # See https://gitlab.haskell.org/ghc/ghc/-/wikis/commentary/libraries/version-history
-  && cabal install --allow-newer cabal-install-$CABAL_VERSION
+  && cabal install --allow-newer --constraint 'Cabal-syntax<3.7' cabal-install-$CABAL_VERSION
 
 FROM alpine:3.16 as builder