title: Auto deployment with gitlab
body: <p>We have Gitlab server running in our office in ubuntu server. I'm doing auto deployment using post-receive hook from each repo. This is what I did,</p>
  
  <ol>
  <li>I wrote shell script in post-receive file to push code from gitlab server to our actual production server.</li>
  <li>So all the repos in our gitlab server has post-receive hook to make auto deployment.</li>
  <li>I installed git bare repo in production server to receive code gitlab server. </li>
  <li>In production server's bare repo I wrote another post-receive hook to deploy the code using <code>GIT_WORK_TREE</code> and restart nginx server in same post-receive hook.</li>
  </ol>
  
  <p>Now I want to make this auto deployment through existing standard tools since with this way of deployment I need to configure all the repo so it will take lot of time again. What are other ways to do this auto deployment.</p>
  
  <p><strong>Production Server</strong>: ubuntu 14.04LTS,
  <strong>Production Webserver</strong>: nginx,
  <strong>local git server</strong>: gitlab.</p>
  
  <p><strong>UPDATE:</strong> I wanted to do this now because I had problem with gitlab shell as @Ciro Santilli explained. And I'm also doing <code>git push production</code> as @Ciro Santilli answer's link mentioned  after I had problem with gitlab shell. But all I wanted to do is what Gitlab_CI does, <code>push to master branch</code> our production server should be updated. I'll try with Gitlab_CI but I wanted to know is there any other tool to do the same.</p>