diff --git a/.docker/Dockerfile b/.docker/Dockerfile
index 60c5e5fa95de1fa037d8e540da44a406abe11585..c240da28f58b537d99eec57e28a27c23d98748fd 100644
--- a/.docker/Dockerfile
+++ b/.docker/Dockerfile
@@ -1,6 +1,6 @@
 FROM debian:latest
 RUN apt-get update && \
-	 apt-get install docker.io tox curl python3-pip git  -y
+	 apt-get install docker.io tox curl python3-pip git python-autopep8 -y
 RUN pip3 install docker-compose
 COPY .docker/wait-for-it.sh /wait-for-it.sh
 RUN git clone https://gitlab.gwdg.de/bmp-caosdb/caosdb-pylib.git && \
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 7cd6307def6f178029e1ac97aca5b9247aad7c46..1054ef611f65d4041fb832ae605a3b669dc797df 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -62,10 +62,12 @@ services:
 
 stages: 
   - setup
+  - style
   - test
 
 test:
   tags: [docker]
+  stage: test
   image: 
     name: docker/compose:1.24.1
     entrypoint: ["/bin/sh", "-c"]
@@ -99,3 +101,10 @@ build-testenv:
         --cache-from $CI_REGISTRY_IMAGE:latest 
         -t $CI_REGISTRY_IMAGE:latest .
       - docker push $CI_REGISTRY_IMAGE:latest
+
+style:
+  tags: [docker]
+  stage: style
+  image: $CI_REGISTRY_IMAGE:latest
+  script:
+      - autopep8 -r --diff --exit-code .