Answer the question
In order to leave comments, you need to log in
Correct deploy Symfony2 project with bower.json and grunt?
Hello!
There is a Symfony2/PHP project that uses Bower and Grunt for front-end development.
Of course, the contents of bower_components and various files minified by Grunt (js, css) do not get into the repository - exactly the same reason why the vendor folder and files like bootstrap.php.cache do not get there.
But we don't want to have a zoo of nodejs, npm, grunt, bower, etc. on the production server, do we? No.
So the only option left is a separate deployer machine on which all our nodejs stuff will be installed. When changes appear in the repository, it will download them, collect, compile / minify everything, and only then upload all the files to the production server with rsync, where there are no nodejs - only what is needed for the application to work.
Can you please tell me if this is the only option?
If so, what did I omit in my reasoning and how best to organize it?
If there are other options - share your thoughts, please.
Thank you.
ZYZH Now everything is assembled on my development machine (because the whole zoo is installed) and rsync is published to the server. I want it to be done by git push.
Answer the question
In order to leave comments, you need to log in
on the CI server, we make a build (tar.gz/deb/rpm) by git push and deploy it. For deployment, since you are using rsync. you can use things like capistrano / capifoni.
ps I recommend looking towards vagrant + ansible to automate infrastructure management. Or even on docker.
Our /etc/project_name.yml file is managed by Puppet. The project itself is assembled on the CI server into a deb package (bower install, gulp build etc are also done there). The postinstall script of the website package says something like
cp /etc/project_name.yml /var/www/project_name/app/config/parameters.yml
. Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question