Category : volumes

For my project I am having issues with docker in docker. Short version of what I do: docker run -v /var/run/docker.sock:/var/run/docker.sock -v /path/to/folder:/path/to/folder –privileged=true –cap-add=CAP_IPC_LOCK –network host -it someimage /bin/bash someimage is based on Ubunut. My host is a Mac. I am mounting /path/to/folder. I also want the docker inside the docker to have access ..

Read more

I am learning about docker and docker compose and I am facing the next issue when I try to run docker-compose up. Let me show my docker-compose.yml services: proxy: image: nginx ports: – ’80:80′ volumes: – ./nginx.conf:/etc/ningx/conf.d/default.conf:ro And this is the error I face: nginx.conf:/etc/ningx/conf.d/default.conf:ro has incorrect format, should be external:internal[:mode] Things I tried: I ..

Read more

The Problem: can’t generate/create files on mounted volumes in docker that is not own by root. Throwing permission denied errors when I create and push my user to docker-compose as well. Scenario: version: ‘3.4’ services: app: image: ubuntu:latest command: /home/john/clone_repository_and_generate_reports.sh volumes: – "/home/john/:/home/john/" environment: – NODE_ENV=production env_file: – ./.config.env My docker-compose.yml file calls to simple ..

Read more

I am currently running a custom built docker container using a docker compose file. The docker compose file looks as follows: version: ‘2’ services: ubuntu: privileged: true image: custom_docker_image:17 container_name: custom_docker_container command: ‘/usr/bin/supervisord’ volumes: – /custom_docker_path/public:/public – /custom_docker_path/data/logs:/data/logs – /custom_docker_path/var/log:/var/log – /custom_docker_path/etc/nginx:/etc/nginx – /custom_docker_path/etc/supervisor:/etc/supervisor – /etc/letsencrypt:/etc/letsencrypt ports: – ‘9202:9200’ The docker container runs services and ..

Read more

Apologies if this is a dumb question but… I am still getting to understand docker, but can’t seem to find an answer to when you would use one of the following over the other in a docker-compose.yaml file: e.g. volumes: – type: bind source: /c/docker/tool/log target: /opt/distribution/log OR volumes: – "c:/docker/tool/log:/opt/distribution/log" Are the above two ..

Read more