A
A
Anton Mashletov2018-02-13 12:12:44
Docker
Anton Mashletov, 2018-02-13 12:12:44

How to properly organize the folder structure of a site under Docker?

For learning purposes, I'm trying to convert an existing php project to docker.
Do I understand correctly that everything related to docker should not be interfered with in a web application and is it better to take it to a higher level? More or less like this:

/containters
   /nginx
   /php
       Dockerfile
   ...
/logs
    /nginx
    /mysql
     ...
/database
  /mysql
/code — корневая директория сайта
  /app
  /config
  /resources
  /public
  artisan
  ...
docker-compose.yml

And how are you? Or can it be mixed with the main site directories?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Maxim Fedorov, 2018-02-13
@mashletov

Project structure:
inside /nginx and /mysql folders (inside each config and dockerfile) and simple dockerfiles (for PHP, Node.js,
Composer, etc...)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question