I have a PHP app (using Symfony) that I’m trying to package with Docker so I can eventually deploy with Kubernetes.
The app consists of a PHP-FPM Docker that sites behind an Nginx one. During development, they share a volume with my code in.
To package the final app up for deployment (e.g.
myapp:1.2.4), is the best practice to:
- Create a Docker that has PHP-FPM and Nginx combined (seems like that’s not a good idea)
- Create a versioned image of both the PHP and Nginx Dockers that each contain the same code (e.g.
myapp-nginx:1.2.4– this seems a bit wasteful, given that a standard
- Work on the basis of k8s having a persistent volume that contains the code that is shared by both
- Something else?
Does anyone have an example of how best to structure it when you have PHP / Nginx to create a versioned app?
Source: Symfony Questions
Was this helpful?
0 / 0