To be honest, I did not care much about deployment through my first years as a web-developer. It happened so that neither projects were small and it was not a problem to just put them using ftp-client or there were always other guys who were in response for that part of the process. Later, the situation changed and I started to look into different tools and technics to put projects online and update them later. When we started Evercode Lab last year this question became even more important as we became responsible for the whole process.

So we started to pay our infrastructure debt and started to use such tools as capistrano and phing to satisfy our needs. And in general, they work quite good for us now. Not perfect, but we are continuously improving the process and its details.

But last week I found a deployment solution that appeared to me as simple as powerfull. Yet, of course, it’s not suitable for every situation. It is very straightforward and can be updated in some details for concrete needs.

Look, here it is:

git archive --format=tar origin/master | gzip -9c | ssh [email protected] "cd /var/www; tar xvzf -"

You can see detailed explanations of each part in the original post. Besides, everything here is quite obvious from the first glance.

Sure, you can put the whole command in one executable file and add some more additional commands and run it just by typing something like $ ./ You can integrate it into other parts of your process.

This deployment solution is sort of meditative for me. It is really fast, easy and clear to understand it every detail.

Feel free to comment here if you know solutions like this or have some ideas on how to make it even better.