V
V
vbNoName2018-05-07 01:56:50
Amazon Web Services
vbNoName, 2018-05-07 01:56:50

What is the best way to organize a server structure on aws with docker containers?

There is a REST api in java, a website in React, and a MySQL database. Accordingly, api written in java works with the database, and upon request from the front, which is written in React, gives it data. I want to deploy all this on aws using docker containers. The question is how to properly organize it all. I don't need a detailed tutorial describing how to do this, just a brief description of how to organize this business.
Deploy 3 docker containers inside one aws instance?
Or docker is not needed for the base, but let it work directly on the instance itself, and make 2 dockers, one for api and the other for react?
Only these two options came to my mind, what else can I do?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Denis Kiselev, 2018-05-07
@deksden

IMHO - to begin with, we wrap each entity in a container, make it able to work either in a single copy, or in the mode of several instances. That is, there must be some kind of load balancer for the API, the web server must also be friends with several workers, the base also scales according to the manuals when several containers appear.
When the whole system is ready to scale, we file the setup required for the current load. Here, the advantage of docker is the ease of migration from one machine to a cluster: you can start with one instance where all containers are spinning, before moving any component to any number of instances.
Something like this.

Y
Yeah, 2018-05-16
@Yeah

Since AWS appears in the question, everything needs to be raised taking into account the services that AWS provides. No three containers per instance!
So, point by point:
Total: only one docker container is needed - for the API.

A
Alexander, 2018-05-07
@alexr64

Why do you need a docker in principle if you have only 1 instance?
Move the database to a separate instance. Wrap in docker and api and website. Depending on the load, ask / give more instances for docker.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question