Questions tagged [docker-stack]

A Docker stack is a set of related services which share volumes, networks and other dependencies, and can be orchestrated and scaled together. "docker stack" is the command from the Docker CLI. Stacks are configured with docker-compose files but a docker stack is complete independent of docker compose.

187 questions
0
votes
1 answer

Exception with connecting to database which runs on separate host in docker stack

I have a trouble with networking in docker compose which runs in docker stack environment. Firt of all I have a project on .NET with dockerized Postgres database which runs in another container. I wrote this two images to docker-compose file (it's…
0
votes
0 answers

Containers on different swarm nodes can't reach eachother

in short, I've got the problem that containers in a swarm can't reach containers that sit on another node. The worker node is in my home network, so not directly accessible externally. Setup: Manager node that is a publicly available server, let's…
Sebaran
  • 1
  • 1
0
votes
0 answers

Docker-compose secrets won't load DEBUG env

I am using the following code in a docker-compose.yml file. I also start the container with "docker stack deploy -c docker-compose.yml default" in windows command prompt. Swarm is active. For the love of god (got to be honest, I've started my…
0
votes
1 answer

Host socket appears as directory in Docker volume

I have a constraint to use unix domain socket for communication between a Docker container and a process on the host machine. The socket on the host machine resides in /tmp/my_socket. For that, I am running the docker container with the mounted…
Martin
  • 378
  • 2
  • 18
0
votes
3 answers

How do I recover Docker Swarm cluster after certificate expired

I had setup a working Docker Swarm cluster, but after several months I am trying to get back to using this cluster and I noticed nothing works. Upon troubleshooting to find out what is going on, I found this error. Plugins: Volume: local …
uberrebu
  • 3,597
  • 9
  • 38
  • 73
0
votes
0 answers

How to docker stack on workers without internet connection

I'm trying to use docker-stack in some machines that only the manager of them can have internet connection. The docker-stack file looks like follows: version: '3.7' networks: monitor-net: services: service: image: aaa/bbb networks: …
zyr17
  • 1
0
votes
1 answer

Docker compose config, --env.file, docker pull and docker stack deploy

I have a problem with these docker commands. I want join the docker compose command to docker stack deploy: I have written the following instructions in my script: docker-compose --env-file $HOME/myinstallation/yml/env config docker-compose…
0
votes
0 answers

Is there a way to bind a Docker overlay Network to a single public IP address?

I have a Docker Swarm with four physical systems in it. With the following docker-compose.yml file version: '3.9' services: web1: image: nginx ports: - 8080:80 I can create a web server with the command docker stack deploy -c…
AlanObject
  • 9,613
  • 19
  • 86
  • 142
0
votes
1 answer

docker services, choose a preferable node to run or rearrange all services if leader comes down

I have 2 swarm nodes and I whish that in case one node shut down, the other one rearrange all services to itself. Right now I have one leader(manager) and one worker, and it works perfectly if the worker goes down, because leader rearranges all…
Gilson
  • 478
  • 7
  • 14
0
votes
1 answer

How to use wait-for-it in docker-stack file?

Here is what I want to do. I want to run myApp1 when myApp2 is up and running. I'm trying to use wait-for-it.sh but I can't seem to make it work. =[ Please help! version: '3' services: myApp1: image: myApp1:latest ports: -…
Sang Kim
  • 33
  • 7
0
votes
1 answer

How to spawn an interactive container in an existing docker swarm?

Note: I've tried searching for existing answers in any way I could think of, but I don't believe there's any information out there on how to achieve what I'm after Context I have an existing swarm running a bunch of networked services across…
mathrick
  • 217
  • 2
  • 11
0
votes
0 answers

Docker swarm - How to ensure service is linked correctly on update

I'm using a compose file to deploy a stack on a swarm. The stack contains (among others) nginx and php-fpm. When updating the stack to newer image tags, using docker stack deploy, I get HTTP 502 errors while the php-fpm service is updating (it take…
yvesb
  • 61
  • 4
0
votes
1 answer

Running specific container on predefined host with docker stack

I have spent lots of time trying to figure out the following scenario but no luck uptil now. so here is the case. I have 2 machines(machine A with IP 123 and machine B with IP 456), 123 is the manager node and 456 is the worker node. Now there are 2…
irshad.ahmad
  • 276
  • 3
  • 9
  • 24
0
votes
1 answer

How to copy files inside a local virtual machine or how to edit a yml file inside a local virtual machine? (docker stack)

I'm following a tutorial on docker stack, swarm, compose, etc. the teacher connects to a VM of the swarm and then deploys a docker stack from this directory docker@node1:~/srv/swarm-stack-1: docker stack deploy -c example-voting-app-stack.yml…
Tms91
  • 3,456
  • 6
  • 40
  • 74
0
votes
0 answers

Use a single docker-compose.yml file with both Docker Compose and Stack, pro and cons?

I'm new of Docker, I'm exploring Docker Compose for development, and Docker Stack over Swarm for production. I'm facing with issues comparing both capabilities, specifically with regard to use of Secrets, that are not supported without Swarm, and…
tmm360
  • 404
  • 4
  • 13