Sulu CMS and GitLab CI CD pipeline tutorial best practice Docker setup

Опубликовано: 21 Март 2022
на канале: Never Code Alone
463
9

A GitLab ci cd pipeline improve your development speed. You can ship and test your PHP Symfony project much faster. In this YouTube tutorial best practice demo Roland Golla shows a full deployment strategy for a new Git feature branch to deploy a new content element for a price overview on a marketing landingpage.

00:00 Intro Sulu CMS mit GitLab CI CD Pipeline Tutorial Best Practice Docker setup
00:24 Git status and compare with branches
01:15 GitKraken for better commit messages
04:07 GitLab ci cd pipeline overview, review and merge request
05:56 GitLab workflow and satges in detail
07:32 PHPUnit testing and E2E Website testing für a feature branch
08:28 Automatic preview and staging environments
11:51 Rancher docker kubernetes cluster
12:31 Outro with benefit tips and arguments

GitLab Code Reviews Tutorial
The benefits for your developer carrer with saving time

Part 1 Sulu CMS Tutorial Setup with DDEV Docker and Symfony CMS
   • Part 1 Sulu CMS Tutorial Setup with D...  

GitLab Pipeline example docker workflow for PHP projects with Symfony, PHPStan, Captain Hook in Sulu
   • Mastering Automated Testing and Deplo...  

GitLab tutorial for beginners continuous integration website testing
   • GitLab tutorial for beginners continu...  

In fact a GitLab ci cd pipeline can deliver your complete work from your local system with a git push to your live system. Lets us take a look on this process. In GitLab you can say that you have different stages. Each stage have multiple tasks to do. All steps can be required or optional. So a website test will fail the full pipeline. To start a supervisior docker container is maybe not nassesary.

In this video there is GitLab ci cd pipeline with a extended flow. The files are published complete to the Sulu CMS project from never code alone The gitlab stages are here build, deplay, test static files, E2E website testing with codeception and rollout.

Never Code Alone and Roland Golle develop all projects with complete docker deployments. This is the best way to build, rollaout, restore and host all PHP projects. On the local system NCA is using the DDEV docker setup to work on different projects, dependecies and PHP versions. The depolyment to staging and live systems is complete setup with docker compose. With this setup and experiance it is a fast and standard way to build and takeover Symfony framework projects. The Sulu CMS is a Symfony fullstack. So you can keep your Symfony project and workflow and just can add new CMS features like content elements to your PHP project.

So on the build task there will be a setup for the docker containers. We have here the PHP application with a composer –no-dev installation, da database container and one PHP container with a complete composer installation to run the tests.

On the deploy task we copy all data – MySQL dump and all user generated content files like images from the actual live system to our new feature branch staging url. Now we can test here everything and ahave a complete stage to present the actual status.

In this status just behind the push, we can do a code review and say when the pipeline is green just merge this branch. A very helpfull GitLab feature. When the feature is merged to the master branch a new preview stage will be build from actual live system with the new files.

Here is a little break to review with the last view. You cal also automate this task with Codeception E2E website testing. Than you can rollout and have a chance to rollback to old docker build or confirm to reopen the master and delete the live container.

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

Our NCA Event Highlights & Live Sessions:

   • Serverless Database Pipeline mit DB B...  

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

Here you can find our social media channels:

► Twitter:   / nevercodealone  
► Instagram:   / nevercodealone  
► LinkedIn:   / never-code-alone  
► Facebook:   / nevercodealone  

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

These are our websites:

► Never Code Alone offers free and commercial live coding events and advanced PHP courses and supports social projects https://nevercodealone.de

► TESTIFY - Website Testing Agency with Cypress.IO and Codeception Testing Framework https://testify.team/

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

You want to support Never Code Alone?
Then feel free to leave us a subscription and write your questions and/or suggestions in the comments.

Thanks for watching!
I hope you enjoyed the video.

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬

Contact: [email protected]