Chapters
24 Chapters
|
2:45:42
|
Login to bookmark this video
-
Course Code
Subscribe to download the code!Compatible PHP versions: >=5.5.9
Subscribe to download the code!Compatible PHP versions: >=5.5.9
-
This Video
Subscribe to download the video!
Subscribe to download the video!
-
Subtitles
Subscribe to download the subtitles!
Subscribe to download the subtitles!
-
Course Script
Subscribe to download the script!
Subscribe to download the script!
24.
When things go wrong: Rollback
Scroll down to the script below, click on any sentence (including terminal blocks) to jump to that spot in the video!
Subscribe to jump to this part in the video!
Keep on Learning!
If you liked what you've learned so far, dive in! Subscribe to get access to this tutorial plus video, code and script downloads.
While the fundamentals of Ansistrano haven't changed, this tutorial is built using Symfony 3, which has significant differences versus Symfony 4 and later.
What PHP libraries does this tutorial use?
// composer.json
{
"require": {
"php": ">=5.5.9",
"doctrine/doctrine-bundle": "^1.6", // 1.6.8
"doctrine/orm": "^2.5", // v2.7.2
"incenteev/composer-parameter-handler": "^2.0", // v2.1.2
"sensio/distribution-bundle": "^5.0.19", // v5.0.20
"sensio/framework-extra-bundle": "^3.0.2", // v3.0.26
"symfony/monolog-bundle": "^3.1.0", // v3.1.0
"symfony/polyfill-apcu": "^1.0", // v1.4.0
"symfony/swiftmailer-bundle": "^2.3.10", // v2.6.3
"symfony/symfony": "3.3.*", // v3.3.5
"twig/twig": "^1.0||^2.0", // v1.34.4
"doctrine/doctrine-migrations-bundle": "^1.2", // v1.2.1
"predis/predis": "^1.1", // v1.1.1
"composer/package-versions-deprecated": "^1.11" // 1.11.99
},
"require-dev": {
"sensio/generator-bundle": "^3.0", // v3.1.6
"symfony/phpunit-bridge": "^3.0", // v3.3.5
"doctrine/data-fixtures": "^1.1", // 1.3.3
"hautelook/alice-bundle": "^1.3" // v1.4.1
}
}
What Ansible libraries does this tutorial use?
# ansible/requirements.yml
-
src: DavidWittman.redis
version: 1.2.4
-
src: ansistrano.deploy
version: 2.7.0
-
src: ansistrano.rollback
version: 2.0.1
6 Comments
Hi,
I just stumbled upon an updated var name for rollback:
ansistrano_rollback_before_symlink_tasks_file instead of the one mentioned in the script ( ansistrano_before_symlink_tasks_file).
Thanks for all.
Cheers
J
Hey Jt-B!
Thanks for mentioning it!
Cheers!
Hey guys:
First of all, happy new year. I hope you have spent a nice holidays.
I was wondering if you are going to update the Ansistrano tutorial using Symfony 5. This has been one of the most useful courses for me and I think I am probably missing something in the configuration to explote all the potential in Symfony 5, maybe with the cache.
Are you planning to do this? Or at least put some little useful notes in the scripts?
Cesar
Hey Cesar!
Happy new year to you too! We did have nice holidays - I always enjoy a bit of quiet around the new year :).
We don't currently have any plans to update this course to Symfony 5, or, it's at least not a priority. But yes, we *do* typically like to add useful notes to tutorials to help extend their usefulness. This might be an opportunity for that!
> I am probably missing something in the configuration to explote all the potential in Symfony 5, maybe with the cache.
What makes you think that you are missing some Symfony 5 potential? Are you seeing errors? Poor performance? Something else?
Let me know :).
Cheers!
Hey Ryan
Thanks for answering!
Sometimes I have errors in the deployment in the part of composer dependencies or in warming up the cache. I didn't identify why but the funny thing is when I run the deploy playbook again, it works perfectly. I don't have the type of errors now but next time I will probably tell you with more details.
My question was more a general wonder. For example, some tweaks to the code like you did in chapter 16. I am not an expert, I just follow your tutorials and things work. That's why I like Symfony.
Cheers.
Cesar
Hey Cesar!
> Sometimes I have errors in the deployment in the part of composer dependencies or in warming up the cache. I didn't identify why but the funny thing is when I run the deploy playbook again, it works perfectly
Got it :). Let us know if/when you see those error again - it's always possible it's something we could address with a note on the tutorial.
> My question was more a general wonder. For example, some tweaks to the code like you did in chapter 16.
Yea... obviously it's hard to think of *all* the possible things that might be different on a Symfony 5.2 app for this tutorial, but not a *lot* of things come to mind... at least not major things. The cache topic you linked to is actually one of the spots that "has" changed the most of the past few years. But actually, that chapter (I believe) is still accurate: if you warm up your cache AND have apcu or Opcache, then nothing "should" be written to your filesystem. That is still true - it had only just recently "become" true when we made this tutorial.
Anyways, that's not a complete answer, but I hope it helps :). Obviously there will be other differences like parameters.yml vs .env files, though it shouldn't make a huge difference. On that topic, I probably would now use Symfony's secrets system instead of Ansible's vault... just because it would make your life a bit easier.
Cheers!
"Houston: no signs of life"
Start the conversation!