diff --git a/Makefile b/Makefile
deleted file mode 100755
index e91b01e8b7ad0d4c745d9ea8dcc8682118f663e9..0000000000000000000000000000000000000000
--- a/Makefile
+++ /dev/null
@@ -1,34 +0,0 @@
-.PHONY: all
-all: build push docker_token template deploy
-
-.PHONY: build
-build:
-	docker build -t ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA} .
-	docker tag ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA} ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:latest
-
-.PHONY: push
-push: build
-	docker push -- ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls
-
-.PHONY: docker_token
-docker_token:
-	kubectl delete secret registry-gitlab -n ${NAMESPACE} --ignore-not-found=true
-	kubectl create secret docker-registry -n ${NAMESPACE} registry-gitlab --docker-server=registry-gitlab.pasteur.fr --docker-username=${DEPLOY_USER} --docker-password=${DEPLOY_TOKEN} --docker-email=kubernetes@pasteur.fr
-
-.PHONY: template
-template:
-	envsubst <polls.yaml >> deploy.yaml
-
-.PHONY: deploy
-deploy: build template push
-	kubectl apply -n ${NAMESPACE} -f deploy.yaml
-
-.PHONY: update
-update:
-	kubectl patch deployment -n ${NAMESPACE} polls -p "{\"spec\":{\"template\":{\"metadata\":{\"labels\":{\"date\":\"`date +'%s'`\"}}}}}"
-
-.PHONY: delete
-delete:
-	kubectl delete deployment -n ${NAMESPACE} polls
-	kubectl delete service -n ${NAMESPACE} polls
-	kubectl delete ingress -n ${NAMESPACE} polls
diff --git a/README.md b/README.md
index b1bc6c3ddc10b4e9ab46d55f2e3fc33af56835cb..db5a2f9c5718120e14073cde9cbc44583abc351b 100644
--- a/README.md
+++ b/README.md
@@ -59,24 +59,20 @@ FROM python:3
 # Here we update the image and add python3 virtualenv
 
 RUN apt-get update && apt-get upgrade -y && apt-get install \
-  -y --no-install-recommends python3 virtualenv
-
-# Create a virtualenv for the application dependencies.
-# # If you want to use Python 2, use the -p python2.7 flag.
-RUN virtualenv -p python3 /env
-ENV PATH /env/bin:$PATH
+  -y --no-install-recommends python3
 
 # Install pip dependencies
 ADD requirements.txt /app/requirements.txt
-RUN /env/bin/pip install --upgrade pip && /env/bin/pip install -r /app/requirements.txt
+RUN pip install --default-timeout=100 --upgrade pip && pip install -r /app/requirements.txt
 
 # We add the current content of the git repo in the /app directory
 ADD . /app
-
+WORKDIR /app
+RUN rm -rf .gitlab-ci.yml Dockerfile README.md img 
 # We use the CMD command to start the gunicorn daemon
 # when we start the container.
 # Note the $PORT variable, we will need to define it when we start the container
-CMD gunicorn -b :$PORT mysite.wsgi
+CMD python manage.py runserver 0.0.0.0:$PORT
 ```
 
 ### Setup Gitlab CI
@@ -94,19 +90,14 @@ stages:
 services:
   - docker:dind
 
-variables:
-  DOCKER_HOST: tcp://localhost:2375
-
 build:
   image: docker:latest
   stage: build
   script:
     - docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
-    - docker build -t ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA} .
-    - docker tag ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA} ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:latest
-    - docker push -- ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls
-  tags:
-    - k8s
+    - docker build -t "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}" .
+    - docker tag "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}" "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:latest"
+    - docker push "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}"
 ```
 
 Save, commit and push; you should be abble to see your first running pipeline
@@ -139,15 +130,15 @@ We do this using a `Persistent Volume Claim`.
 apiVersion: v1
 kind: PersistentVolumeClaim
 metadata:
-name: postgres-claim
-labels:
-    app: postgresql
+  name: postgres-claim
+  labels:
+      app: postgresql
 spec:
-accessModes:
-    - ReadWriteOnce
-resources:
-    requests:
-    storage: 1Gi
+  accessModes:
+      - ReadWriteOnce
+  resources:
+      requests:
+        storage: 1Gi
 ```
 
 ##### PostgreSQL secret
@@ -162,65 +153,76 @@ We are here defining the PostgreSQL basic parameters : username, password and da
 apiVersion: v1
 kind: Secret
 metadata:
-name: postgresql-credentials
+  name: postgresql-credentials
 type: Opaque
 data:
-username: cG9sbHNfdXNlcgo=
-password: c2xsb3BfYzNiaQo=
-database: cG9sbHMK
+  username: cG9sbHNfdXNlcgo=
+  password: cG9sbHMK
+  database: cG9sbHMK
 ```
 
 ##### PostgreSQL Deployment
 
 ```yaml
-apiVersion: extensions/v1beta1
+apiVersion: apps/v1
 kind: Deployment
 metadata:
-name: postgresql
-labels:
+  name: postgresql
+  labels:
     app: postgresql
 spec:
-strategy:
+  replicas: 1
+  selector:
+    matchLabels:
+      app: postgresql
+  strategy:
     type: Recreate
-template:
+  template:
     metadata:
-    labels:
+      labels:
         app: postgresql
         tier: postgreSQL
     spec:
-    containers:
-        - image: postgres:9.6.2-alpine
-        name: postgresql
+      containers:
+      - name: postgresql
+        image: postgres:9.6.2-alpine
         env:
-            - name: POSTGRES_USER
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: username
-            - name: POSTGRES_DB
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: database
-            - name: POSTGRES_PASSWORD
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: password
+        - name: POSTGRES_USER
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: username
+        - name: POSTGRES_DB
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: database
+        - name: POSTGRES_PASSWORD
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: password
         ports:
-            - containerPort: 5432
-            name: postgresql
+        - containerPort: 5432
+          name: postgresql
+        resources:
+          requests:
+            memory: "64Mi"
+            cpu: "50m"
+          limits:
+            memory: "128Mi"
+            cpu: "100m"  
         volumeMounts:
-            - name: postgresql
-            mountPath: /var/lib/postgresql/data
-            subPath: data
-    volumes:
         - name: postgresql
+          mountPath: /var/lib/postgresql/data
+          subPath: data
+      volumes:
+      - name: postgresql
         persistentVolumeClaim:
-            claimName: postgres-claim
-        - name: postgresql-credentials
+          claimName: postgres-claim
+      - name: postgresql-credentials
         secret:
-            secretName: postgresql
+          secretName: postgresql-credentials
 ```
 
 ##### PostgreSQL Service
@@ -229,13 +231,13 @@ template:
 apiVersion: v1
 kind: Service
 metadata:
-name: postgresql
-labels:
+  name: postgresql
+  labels:
     app: postgresql
 spec:
-ports:
+  ports:
     - port: 5432
-selector:
+  selector:
     app: postgresql
     tier: postgreSQL
 ````
@@ -244,48 +246,61 @@ selector:
 ##### Deployment
 
 ```yaml
-apiVersion: extensions/v1beta1
+apiVersion: apps/v1
 kind: Deployment
 metadata:
-name: polls
-labels:
-    app: polls
+  name: polls
+  labels:
+      app: polls
 spec:
-replicas: 3
-template:
+  replicas: 1
+  selector:
+    matchLabels:
+      app: polls
+  template:
     metadata:
-    labels:
+      labels:
         app: polls
     spec:
-    containers:
-    name: polls-app
-        image: ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA}
-        # This setting makes nodes pull the docker image every time before
-        # starting the pod. This is useful when debugging, but should be turned
-        # off in production.
+      containers:
+      - name: polls-app
+        image: $CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}
         imagePullPolicy: Always
         env:
-            - name: DATABASE_NAME
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: database
-            - name: DATABASE_USER
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: username
-            - name: DATABASE_PASSWORD
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: password
+        - name: DATABASE_HOST
+          value: postgresql
+        - name: DATABASE_NAME
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: database
+        - name: DATABASE_USER
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: username
+        - name: DATABASE_PASSWORD
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: password
+        - name: PORT
+          value: "8080"
         ports:
         - containerPort: 8080
-    volumes:
-        - name: postgresql-credentials
+        resources:
+          requests:
+            memory: "64Mi"
+            cpu: "50m"
+          limits:
+            memory: "128Mi"
+            cpu: "100m"  
+      imagePullSecrets:
+        - name: registry-gitlab
+      volumes:
+      - name: postgresql-credentials
         secret:
-            secretName: postgresql
+          secretName: postgresql-credentials
 ```
 
 ##### Service
@@ -294,15 +309,14 @@ template:
 apiVersion: v1
 kind: Service
 metadata:
-name: polls
-labels:
+  name: polls
+  labels:
     app: polls
 spec:
-type: ClusterIP
-ports:
-- port: 80
-    targetPort: 8080
-selector:
+  type: ClusterIP
+  ports:
+  - port: 8080
+  selector:
     app: polls
 ```
 
@@ -312,57 +326,68 @@ selector:
 apiVersion: extensions/v1beta1
 kind: Ingress
 metadata:
-annotations:
+  annotations:
     kubernetes.io/ingress.class: traefik
-labels:
+  labels:
     app: polls
-name: polls
+  name: polls
 spec:
-rules:
-- host: https://${CI_PROJECT_NAME}.k8s-dev.pasteur.fr
+  rules:
+  - host: ${GITLAB_USER_LOGIN}.k8s-dev.pasteur.fr
     http:
-    paths:
-    - backend:
-        serviceName: polls
-        servicePort: 80
+      paths:
+      - backend:
+          serviceName: polls
+          servicePort: 8080
         path: /
 ```
 
 ##### Kubernetes Job
 
+Create a file `job.yaml` at the root directory of your git repository and fill it with the following definition.
+
 We will use a `Job` in order to manage django migrations.
-> Note: Kubernetes jobs are run only once opposed to `Deployments` that run continiously.
+> Note: Kubernetes jobs are run only once opposed to `Deployments` that run continiously. We put it in a seperate file because a Job is immutable and cannot be updated.
 
 ```yaml
+---
 apiVersion: batch/v1
 kind: Job
 metadata:
-name: polls-migrations
+  name: polls-migrations
 spec:
-template:
-    spec:
-    containers:
-        - name: django
-        image: ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA}
-        command: ['python', 'manage.py', 'migrate']
-        env:
-            - name: DATABASE_NAME
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: database
-            - name: DATABASE_USER
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: username
-            - name: DATABASE_PASSWORD
-            valueFrom:
-                secretKeyRef:
-                name: postgresql-credentials
-                key: password
-    restartPolicy: Never
-backoffLimit: 5
+  template:
+      spec:
+        containers:
+            - name: django
+              image: $CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}
+              command: ['python', '/app/manage.py', 'migrate']
+              env:
+              - name: DATABASE_HOST
+                value: postgresql
+              - name: DATABASE_NAME
+                valueFrom:
+                  secretKeyRef:
+                    name: postgresql-credentials
+                    key: database
+              - name: DATABASE_USER
+                valueFrom:
+                  secretKeyRef:
+                    name: postgresql-credentials
+                    key: username
+              - name: DATABASE_PASSWORD
+                valueFrom:
+                  secretKeyRef:
+                    name: postgresql-credentials
+                    key: password
+        restartPolicy: Never
+        imagePullSecrets:
+          - name: registry-gitlab
+        volumes:
+        - name: postgresql-credentials
+          secret:
+            secretName: postgresql-credentials
+  backoffLimit: 5
 ```
 
 ### Setup Continuous Delivery in Gitlab CI
@@ -372,17 +397,18 @@ deploy:
   stage: deploy
   image: registry-gitlab.pasteur.fr/dsi-tools/docker-images:docker_kubernetes_image
   variables:
-    NAMESPACE: "mynamespace"
+    NAMESPACE: "<your gitlab user>-django"
   environment:
-    name: mynamespace
-    url: https://${CI_PROJECT_NAME}.k8s-dev.pasteur.fr
+    name: <your gitlab user>-django
+    url: https://<your gitlab user>-django.k8s-dev.pasteur.fr
   script:
+    - yum install -y gettext
     - kubectl delete secret registry-gitlab -n ${NAMESPACE} --ignore-not-found=true
     - kubectl create secret docker-registry -n ${NAMESPACE} registry-gitlab --docker-server=registry-gitlab.pasteur.fr --docker-username=${DEPLOY_USER} --docker-password=${DEPLOY_TOKEN} --docker-email=kubernetes@pasteur.fr
-    - envsubst < polls.yaml | kubectl apply -f -
+    - envsubst < manifest.yaml | kubectl apply -n ${NAMESPACE} -f -
+    - kubectl delete job polls-migrations -n ${NAMESPACE} --ignore-not-found=true
+    - envsubst < job.yaml | kubectl apply -n ${NAMESPACE} -f -
     - kubectl patch deployment polls -p "{\"spec\":{\"template\":{\"metadata\":{\"labels\":{\"date\":\"`date +'%s'`\"}}}}}"
-  tags:
-    - k8s
 ```
 
 ## What else ?
@@ -396,4 +422,4 @@ deploy:
 ### Grafana : Metrics and Logs
 
 ### Best Practices
-Always use Gitlab
\ No newline at end of file
+Always use Gitlab !!!
\ No newline at end of file
diff --git a/mysite/settings.py b/mysite/settings.py
index cba76a7b82914e827e14237ad762a302eb965b35..d56e54fcfe4dbfdbbff789a33255a65ed4ee37a9 100755
--- a/mysite/settings.py
+++ b/mysite/settings.py
@@ -82,10 +82,10 @@ DATABASES = {
         # If you are using Cloud SQL for MySQL rather than PostgreSQL, set
         # 'ENGINE': 'django.db.backends.mysql' instead of the following.
         'ENGINE': 'django.db.backends.postgresql',
-        'NAME': 'polls',
+        'NAME': os.getenv('DATABASE_NAME'),
         'USER': os.getenv('DATABASE_USER'),
         'PASSWORD': os.getenv('DATABASE_PASSWORD'),
-        'HOST': os.getenv('DATABASE_NAME'),
+        'HOST': os.getenv('DATABASE_HOST'),
         'PORT': '5432',
     }
 }
diff --git a/polls.yaml b/polls.yaml
deleted file mode 100755
index 9c67cf479d7e435c3d9b9f9849cadea926102325..0000000000000000000000000000000000000000
--- a/polls.yaml
+++ /dev/null
@@ -1,69 +0,0 @@
-apiVersion: extensions/v1beta1
-kind: Deployment
-metadata:
-  name: polls
-  labels:
-    app: polls
-spec:
-  replicas: 3
-  template:
-    metadata:
-      labels:
-        app: polls
-    spec:
-      containers:
-       name: polls-app
-        image: ${CI_REGISTRY}/${CI_PROJECT_NAME}/polls:${CI_COMMIT_SHORT_SHA}
-        # This setting makes nodes pull the docker image every time before
-        # starting the pod. This is useful when debugging, but should be turned
-        # off in production.
-        imagePullPolicy: Always
-        env:
-            - name: DATABASE_USER
-              valueFrom:
-                secretKeyRef:
-                  name: postgresql-credentials
-                  key: username
-            - name: DATABASE_PASSWORD
-              valueFrom:
-                secretKeyRef:
-                  name: postgresql-credentials
-                  key: password
-        ports:
-        - containerPort: 8080
-      volumes:
-        - name: postgresql-credentials
-          secret:
-            secretName: postgresql
----
-apiVersion: v1
-kind: Service
-metadata:
-  name: polls
-  labels:
-    app: polls
-spec:
-  type: ClusterIP
-  ports:
-  - port: 80
-    targetPort: 8080
-  selector:
-    app: polls
----
-apiVersion: extensions/v1beta1
-kind: Ingress
-metadata:
-  annotations:
-    kubernetes.io/ingress.class: traefik
-  labels:
-    app: polls
-  name: polls
-spec:
-  rules:
-  - host: ${CI_PROJECT_NAME}.pasteur.cloud
-    http:
-      paths:
-      - backend:
-          serviceName: polls
-          servicePort: 80
-        path: /
\ No newline at end of file
diff --git a/requirements.txt b/requirements.txt
index c19a8e2bed0a30e6f5f1e4436c64745cf0da5c6f..8b7f66a29c885ef35d2ad448ba719a38484c3fce 100755
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,5 +1,3 @@
 Django==2.1.5
-mysqlclient==1.4.1
 wheel==0.32.3
-gunicorn==19.9.0
 psycopg2==2.7.7
diff --git a/solution/.gitlab-ci.yml b/solution/.gitlab-ci.yml
new file mode 100644
index 0000000000000000000000000000000000000000..a0dcbd2b859e1dd5a27618e824caf1f9570dfb97
--- /dev/null
+++ b/solution/.gitlab-ci.yml
@@ -0,0 +1,32 @@
+stages:
+  - build
+  - deploy
+
+services:
+  - docker:dind
+
+build:
+  image: docker:latest
+  stage: build
+  script:
+    - docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
+    - docker build -t "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}" .
+    - docker tag "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}" "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:latest"
+    - docker push "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}"
+
+deploy:
+  stage: deploy
+  image: registry-gitlab.pasteur.fr/dsi-tools/docker-images:docker_kubernetes_image
+  variables:
+    NAMESPACE: "tmenard-django"
+  environment:
+    name: tmenard-django
+    url: https://tmenard-django.k8s-dev.pasteur.fr
+  script:
+    - kubectl delete secret registry-gitlab -n ${NAMESPACE} --ignore-not-found=true
+    - kubectl create secret docker-registry -n ${NAMESPACE} registry-gitlab --docker-server=registry-gitlab.pasteur.fr --docker-username=${DEPLOY_USER} --docker-password=${DEPLOY_TOKEN} --docker-email=kubernetes@pasteur.fr
+    - envsubst < manifest.yaml | kubectl apply -n ${NAMESPACE} -f -
+    - kubectl delete job polls-migrations -n ${NAMESPACE} --ignore-not-found=true
+    - envsubst < job.yaml | kubectl apply -n ${NAMESPACE} -f -
+    - kubectl patch deployment polls -p "{\"spec\":{\"template\":{\"metadata\":{\"labels\":{\"date\":\"`date +'%s'`\"}}}}}"
+
diff --git a/Dockerfile b/solution/Dockerfile
similarity index 65%
rename from Dockerfile
rename to solution/Dockerfile
index 46c11ea64b133818ea4dbed1ae6a52a5550db5e1..3eccf454a6fc374ceb0c2e8764cc85d8f4eb5381 100755
--- a/Dockerfile
+++ b/solution/Dockerfile
@@ -8,21 +8,17 @@ FROM python:3
 # Here we update the image and add python3 virtualenv
 
 RUN apt-get update && apt-get upgrade -y && apt-get install \
-  -y --no-install-recommends python3 virtualenv
-
-# Create a virtualenv for the application dependencies.
-# # If you want to use Python 2, use the -p python2.7 flag.
-RUN virtualenv -p python3 /env
-ENV PATH /env/bin:$PATH
+  -y --no-install-recommends python3
 
 # Install pip dependencies
 ADD requirements.txt /app/requirements.txt
-RUN /env/bin/pip install --upgrade pip && /env/bin/pip install -r /app/requirements.txt
+RUN pip install --default-timeout=100 --upgrade pip && pip install -r /app/requirements.txt
 
 # We add the current content of the git repo in the /app directory
 ADD . /app
-
+WORKDIR /app
+RUN rm -rf .gitlab-ci.yml Dockerfile README.md img 
 # We use the CMD command to start the gunicorn daemon
 # when we start the container.
 # Note the $PORT variable, we will need to define it when we start the container
-CMD gunicorn -b :$PORT mysite.wsgi
+CMD python manage.py runserver 0.0.0.0:$PORT
diff --git a/solution/job.yaml b/solution/job.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..6f6966b98ee3e6e97f8690d0f77c0261188d128f
--- /dev/null
+++ b/solution/job.yaml
@@ -0,0 +1,39 @@
+---
+apiVersion: batch/v1
+kind: Job
+metadata:
+  name: polls-migrations
+spec:
+  template:
+      spec:
+        containers:
+            - name: django
+              image: $CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}
+              command: ["/bin/sh","-c"]
+              args: ["python manage.py makemigrations && python manage.py migrate"]
+              env:
+              - name: DATABASE_HOST
+                value: postgresql
+              - name: DATABASE_NAME
+                valueFrom:
+                  secretKeyRef:
+                    name: postgresql-credentials
+                    key: database
+              - name: DATABASE_USER
+                valueFrom:
+                  secretKeyRef:
+                    name: postgresql-credentials
+                    key: username
+              - name: DATABASE_PASSWORD
+                valueFrom:
+                  secretKeyRef:
+                    name: postgresql-credentials
+                    key: password
+        restartPolicy: Never
+        imagePullSecrets:
+          - name: registry-gitlab
+        volumes:
+        - name: postgresql-credentials
+          secret:
+            secretName: postgresql-credentials
+  backoffLimit: 5
diff --git a/solution/manifest.yaml b/solution/manifest.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..1fc0778512e3c45b810aa54a0a382bc83640e52b
--- /dev/null
+++ b/solution/manifest.yaml
@@ -0,0 +1,183 @@
+---
+apiVersion: v1
+kind: PersistentVolumeClaim
+metadata:
+  name: postgres-claim
+  labels:
+      app: postgresql
+spec:
+  accessModes:
+      - ReadWriteOnce
+  resources:
+      requests:
+        storage: 1Gi
+---
+apiVersion: v1
+kind: Secret
+metadata:
+  name: postgresql-credentials
+type: Opaque
+data:
+  username: cG9sbHNfdXNlcgo=
+  password: cG9sbHMK
+  database: cG9sbHMK
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: postgresql
+  labels:
+    app: postgresql
+spec:
+  replicas: 1
+  selector:
+    matchLabels:
+      app: postgresql
+  strategy:
+    type: Recreate
+  template:
+    metadata:
+      labels:
+        app: postgresql
+        tier: postgreSQL
+    spec:
+      containers:
+      - name: postgresql
+        image: postgres:9.6.2-alpine
+        env:
+        - name: POSTGRES_USER
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: username
+        - name: POSTGRES_DB
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: database
+        - name: POSTGRES_PASSWORD
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: password
+        ports:
+        - containerPort: 5432
+          name: postgresql
+        resources:
+          requests:
+            memory: "64Mi"
+            cpu: "50m"
+          limits:
+            memory: "128Mi"
+            cpu: "100m"  
+        volumeMounts:
+        - name: postgresql
+          mountPath: /var/lib/postgresql/data
+          subPath: data
+      volumes:
+      - name: postgresql
+        persistentVolumeClaim:
+          claimName: postgres-claim
+      - name: postgresql-credentials
+        secret:
+          secretName: postgresql-credentials
+---
+apiVersion: v1
+kind: Service
+metadata:
+  name: postgresql
+  labels:
+    app: postgresql
+spec:
+  ports:
+    - port: 5432
+  selector:
+    app: postgresql
+    tier: postgreSQL
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: polls
+  labels:
+      app: polls
+spec:
+  replicas: 1
+  selector:
+    matchLabels:
+      app: polls
+  template:
+    metadata:
+      labels:
+        app: polls
+    spec:
+      containers:
+      - name: polls-app
+        image: $CI_REGISTRY_IMAGE/$CI_COMMIT_REF_NAME/polls:${CI_COMMIT_SHORT_SHA}
+        imagePullPolicy: Always
+        env:
+        - name: DATABASE_HOST
+          value: postgresql
+        - name: DATABASE_NAME
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: database
+        - name: DATABASE_USER
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: username
+        - name: DATABASE_PASSWORD
+          valueFrom:
+            secretKeyRef:
+              name: postgresql-credentials
+              key: password
+        - name: PORT
+          value: "8080"
+        ports:
+        - containerPort: 8080
+        resources:
+          requests:
+            memory: "64Mi"
+            cpu: "50m"
+          limits:
+            memory: "128Mi"
+            cpu: "100m"  
+      imagePullSecrets:
+        - name: registry-gitlab
+      volumes:
+      - name: postgresql-credentials
+        secret:
+          secretName: postgresql-credentials
+---
+apiVersion: v1
+kind: Service
+metadata:
+  name: polls
+  labels:
+    app: polls
+spec:
+  type: ClusterIP
+  ports:
+  - port: 8080
+  selector:
+    app: polls
+---
+apiVersion: extensions/v1beta1
+kind: Ingress
+metadata:
+  annotations:
+    kubernetes.io/ingress.class: traefik
+  labels:
+    app: polls
+  name: polls
+spec:
+  rules:
+  - host: ${GITLAB_USER_LOGIN}.k8s-dev.pasteur.fr
+    http:
+      paths:
+      - backend:
+          serviceName: polls
+          servicePort: 8080
+        path: /