Hot answers tagged

105 votes
Accepted

What is the difference between a library and a dependency?

Libraries and dependencies are like persons and relatives: One is just an entity (something), the other is a relational entity. I am a person. My niece is also a person. But to her, I'm a relative. ...
Kilian Foth's user avatar
87 votes
Accepted

Are the development benefits of using Docker negated when using Java compared to other languages closer to Unix binaries?

Not at all. Imagine you're running the version 1.8.0 of Java on both your development machine and the server. By the way, you're working simultaneously on two projects, both using Java. One day, a ...
Arseni Mourzenko's user avatar
41 votes

What is the difference between a library and a dependency?

If an application uses a library, the application has a dependency on that library. Libraries are not the only type of dependency an application can have. Software can also depend on: configuration ...
Rik D's user avatar
  • 4,709
35 votes

Are the development benefits of using Docker negated when using Java compared to other languages closer to Unix binaries?

You rarely just deploy a "Java App". Your java application has a lot of different support programs around it. We use Apache HTTPD, Apache Tomcat, ActiveMQ for messaging, an FTP Deamon, MySQL and a ...
Bill K's user avatar
  • 2,739
13 votes
Accepted

Are there benefits to running my development environment in a Docker container?

This is not an uncommon problem, but Docker isn't really the right tool to solve it. Containers in general (including Docker) are intended to provide an application runtime for a single process, such ...
Dan1701's user avatar
  • 3,118
13 votes

Should I include tests in Docker image?

For running build-time tests, the preferred way would be to use a multi-stage build. Multi-stage Dockerfiles allow you to have a larger stage with all the dependencies for building and testing, then ...
Karl Bielefeldt's user avatar
12 votes

What is the difference between a library and a dependency?

Dependency In Docker image you have dependencies on different types and versions of: underlying OS (CentOS, Debian, Windows, ...) database (Mongo, Postgresql, ElasticSearch, ...) tools, and ...
RenatoIvancic's user avatar
12 votes

Would we need Docker if applications were better behaved?

A major benefit of virtual machines and containers is the way you can isolate an application from any other applications, and reason about it as being a separate entity with clear interfaces that you ...
Arseni Mourzenko's user avatar
11 votes
Accepted

Different Redis instances for different microservices?

If we consider the cache to be orthogonal to the architecture (and it's), the first pic is ok. For the same reason that we don't deploy one security service, one API gateway, one message broker or ...
Laiv's user avatar
  • 14.5k
11 votes

What is the difference between a library and a dependency?

A library is a specific piece of software that is intended to be consumed by another program. Typically, the library will address a specific/group of specific issues (although they can sometimes grow ...
Brian Place's user avatar
10 votes
Accepted

What are the reasons to use docker in your software development process if you're not using it in production?

Here are some reasons why we use docker as part of our software development process (we don't use it in production yet): Consistent and version controlled local deployment environment - we check our ...
Samuel's user avatar
  • 9,167
10 votes

Should I include tests in Docker image?

There is a third way, as you said yourself. I think you are mixing up development, testing and deployment. I propose that the whole SDLC be looked at as a whole, first, to understand what it is you ...
avastmick's user avatar
  • 101
9 votes

Are the development benefits of using Docker negated when using Java compared to other languages closer to Unix binaries?

This question would also be pertinent for golang, where you can just extract statically linked binaries and run them somewhere, as opposed to Python or C++ where you usually have a large number of ...
Yannick's user avatar
  • 99
8 votes

Multi tenancy or multi instance?

I am asking myself the exact same question at the moment. I am leaning towards the multi-instance single tenancy solution but have not taken a definitive decision yet. Let me share some of my ...
Pierre Henry's user avatar
8 votes
Accepted

best way to install local package into docker image

I'm not sure why people have downvoted you, other than there is a well documented and easy way to go about this. Docker images are layered, and you can build all your essential-for-all-images ...
Mitch Kent's user avatar
8 votes

Different Redis instances for different microservices?

Separate services should use separate REDIS instances. Reason: Bad usage of REDIS by another service, causing REDIS outage, should not impact your application. Only queues which are used for inter-...
Sahil Gupta's user avatar
8 votes

Docker: One container per database?

Last time I checked it is not recommend to run databases in docker. Simply put docker is designed to be a stateless container that you can spin up and take down as required. Where as Databases are ...
Ewan's user avatar
  • 72.4k
8 votes

What exactly is a REST API in reference to Docker?

I think this is a good question and you could similarly ask why a locally installed IDE is built on top of a web browser. I think the root answer lies in the increasing connectivity to and reliance ...
JimmyJames's user avatar
  • 25.9k
7 votes
Accepted

How to properly create a local development environment based on a Docker based micro-service architecture?

Microservices should be relatively independent of each other. During developer testing, you should be able to only start the one you are working on and perhaps two or three others, usually related to ...
Karl Bielefeldt's user avatar
7 votes
Accepted

At what point does a microservices architecture become "worth it" vs. a monolithic ASP.NET web application?

As I see it, the size of the application doesn't really have much to do with the microservices pattern. After all, you can always choose to build a few large monoliths or to build a monolith out of ...
Michael's user avatar
  • 6,457
7 votes

I want my Docker container to use more of the host's CPU resources

Usually docker container resources are not limited by default. You have to explicitly ask for stricter limits. Without more information, my guess would be that the problem is in your app, not in ...
Karl Bielefeldt's user avatar
6 votes

Docker, microservices and git workflow

It sounds like your problem is you are putting all your microservices into the same "development environment image" as you describe. So any service container can see all others. What you should be ...
enderland's user avatar
  • 12.1k
6 votes

Are the development benefits of using Docker negated when using Java compared to other languages closer to Unix binaries?

This is a really good question but after working with Docker, I would turn it around: Are the benefits of the JVM negated by containerization (e.g. Docker)? Containers really challenge a lot of ...
JimmyJames's user avatar
  • 25.9k
6 votes

Are Docker images tied to CPU architectures?

TL;DR your idea won't work, for several reasons. In general, yes, docker images are tied to CPU architectures. It is probably possible to run docker under a CPU emulator but you most likely won't be ...
Hans-Martin Mosner's user avatar
6 votes

What's the best way to get GitLab Docker runners and Python tox to work together?

Our team is using poetry with configurations included in pyproject.toml for dependency management, and the Dockerfile looks like FROM some image COPY pyproject.toml . COPY poetry.lock . RUN poetry ...
lennon310's user avatar
  • 3,162
5 votes

Splitting application code and docker deployment files

It often makes sense to version docker-compose.yml files separately from your application, because they are specific to different deployments, and reference multiple docker images from several ...
Karl Bielefeldt's user avatar
5 votes
Accepted

Are there worthwhile advantages to creating a separate docker container to handle http?

There are a number of reasons: The instances can be scaled differently. For example, databases usually require a minimum of 3 physically-separated nodes for durability, where a web server usually ...
Karl Bielefeldt's user avatar
5 votes

What are the benefits of Docker?

The primary advantage of Docker is the ability to create wholly deployable applications as build artifacts. The deployable applications can be run through test suites that verify that they operate ...
Alain O'Dea's user avatar
5 votes

Do I need to secure communications between microservices in a cluster?

It depends, what are they actually doing? If you’re handling health or banking records, you should probably secure the communications since there is usually a legal requirement to do so. If you’re ...
Telastyn's user avatar
  • 109k
5 votes

Docker: One container per database?

Containers are ultimately just small wrappers around processes (not machines!) and it is helpful to think about them in terms of that. In this case, each database has its own long-lived master process,...
gntskn's user avatar
  • 274

Only top scored, non community-wiki answers of a minimum length are eligible