P
P
pavels912016-05-17 13:36:28
linux
pavels91, 2016-05-17 13:36:28

Who understands docker?

I work on a bunch of Linux, PHP, Muscle, Apache. Recently tried docker. The essence of the separation by containers is clear, for php its own, for the muscle its own, for access to the FS its own, etc. Why this is done is also clear. But there is no complete picture, so to speak, from the developer's machine to the upload to the server.
Here are a few questions:
- I have images of all the above services and I decided to share them with another developer. Ok, done, working. Then we decide to jump from php 5.6 to 7. Between ourselves, no problem, but how to send this case to a working server, not with handles?
- with the FS is generally a dead end. What to do, how to update, for example, the database with migrations so that the product receives a ready-made database and raw site engine? There are suspicions that this has nothing to do with the docker.
Can anyone share a link to an article(s) where the whole docker puzzle is put together? Not necessarily under php, apache, etc. The main thing is to get the gist.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey, 2016-05-17
@pavels91

to access your FS

No, use named volumes to access the FC. Containers (data-only) are needed for this.
docker registry, or use a paid one or install it at home and store images there. That is, if someone decides to upgrade to php7.0, we must replace the base container, check that everything works, push ... and everything will be pulled up for everyone.
Exactly, nothing to docker. I usually run migrations right at the start of the container. So more reliable.
On the article - no, there are a lot of them. I can share how I use docker in my projects. It describes the process of assembly and deployment in stealth. Ideally, the build and deployment should be managed by the CI server and not by hand locally:
https://github.com/intellectsoft-uk/symfony-skeleton

Николай, 2016-05-17
@healqq

1. docker-compose решает все проблемы(ну или почти все) ссылка
2. для миграций, сборок, обновления зависимостей через composer/npm/.... можно сделать контейнер(ы) который будет выполнять необходимую команду(например composer install) при запуске docker-compose и выключаться. При необходимости повторного выполнения какой-то операции - можно просто запустить этот контейнер заново. Ну перезапустить весь compose.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question