diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 9189c7260fa90228ced08f9ed0f02bd7cac239c2..c9e8c4f428649a19e36f594e55ec843995742094 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -10,10 +10,31 @@
   - make install
 
 stages:
+  - license
   - build_and_test
   - deploy
   - final
 
+license_header:
+  stage: license
+  image: labrobotica/wolf_deps:16.04
+  before_script:
+    - 'which ssh-agent || ( apt-get update -qy && apt-get install openssh-client -qqy )'
+    - eval `ssh-agent -s`
+    - echo "${SSH_PRIVATE_KEY}" | tr -d '\r' | ssh-add - > /dev/null # add ssh ke
+    - mkdir -p ~/.ssh
+    - chmod 700 ~/.ssh
+    - echo "$SSH_PUBLIC_KEY" >> ~/.ssh/id_rsa.pub
+    - '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
+  script:
+    - git config --global user.email "${CI_EMAIL}"
+    - git config --global user.name "${CI_USERNAME}"
+    - touch prova.txt
+    - git add -f prova.txt
+    - git commit -m "added prova.txt" || echo "No changes, nothing to commit!"
+    - git remote rm origin && git remote add origin git@gitlab.com:$CI_PROJECT_PATH.git
+    - git push origin HEAD:$CI_COMMIT_REF_NAME # Pushes to the same branch as the trigger
+
 build_and_test:xenial:
   stage: build_and_test
   image: labrobotica/wolf_deps:16.04