Member-only story
Automate deploying a Dockerized PHP application with Gitlab CI
Documenting my experiments with Gitlab CI to deploy a Dockerized PHP application.
Overview
In most projects, we have to wrangle with different CI Servers, Container Repositories and Source Code Repositories and weave them together such that they can finally sing the song of continuous integration and deployment in a harmonious chorus.
In this example, I am going to experiment with idea of completely trying to solve my CI/CD on Gitlab, making use of their complete suite of tools to finally get my bundled application onto production server.
Oh did I also mentioned that this is completely free?!
The Project
A quick comment on the project setup. Because the intent of this project is to learn more about Gitlab than the docker/nginx/php setup, the barebones PHP web application that while slightly contrived, aims to meet the learning objectives.
- Trivial PHP web application that prints out the ‘hello world’.
- Web server running on nginx + php-fpm.
- Only one docker container without any persistence layer.
- Use supervisor to run and manage nginx and php-fpm processes.