docker-compose

Why do I still need to do COPY in my Dockerfile if I'm using a Bind Mount?

坚强是说给别人听的谎言 提交于 2021-01-05 06:22:59
问题 So I'm in a developemnt environment and I'm binding my code inside a container using Mount Bind in my docker-compose file: ... volumes: - ./my-code:/home/node/app - /home/node/app/node_modules ... But I still need do COPY inside my Dockerfile in order to make this work. COPY --chown=node:node . . What I don't get is. If I'm binding my code to the container inside docker-compose.yml, why do I still need to copy all my code in the Dockerfile? 来源: https://stackoverflow.com/questions/62734082/why

Why do I still need to do COPY in my Dockerfile if I'm using a Bind Mount?

Deadly 提交于 2021-01-05 06:22:31
问题 So I'm in a developemnt environment and I'm binding my code inside a container using Mount Bind in my docker-compose file: ... volumes: - ./my-code:/home/node/app - /home/node/app/node_modules ... But I still need do COPY inside my Dockerfile in order to make this work. COPY --chown=node:node . . What I don't get is. If I'm binding my code to the container inside docker-compose.yml, why do I still need to copy all my code in the Dockerfile? 来源: https://stackoverflow.com/questions/62734082/why

NiFi UI not accessible when started from docker-compose

隐身守侯 提交于 2021-01-05 05:55:57
问题 For the life of me I can't get to the NiFi Web UI. It makes me hate security. TLDR; I can't find the right way to start NiFi in a docker container and still access the UI. Here's what I've tried (for 8 hours): docker run --name nifi \ -p 8080:8080 \ -d \ apache/nifi:latest I go to localhost:8080/nifi - timeout. Same on 127.0.0.1 . docker inspect nifi - IP Gateway is 172.20.0.1 with actual IP of 172.0.0.2 . Invalid Host Header and timeout, respectively. Start randomly trying stuff: # I tried

docker “mysqld: can't read dir of '/etc/mysql/mysql.conf.d' (os errno 2 - no such file or directory)”

不羁岁月 提交于 2021-01-04 06:00:40
问题 I have installed docker-engine and docker-compose on my Ubuntu 16.04 machine. When installing docker-engine, I followed: https://www.0x90.it/come-installare-e-usare-docker-su-ubuntu-16-04/ When running the command "docker-compose -f docker-compose-dev.yml up -d", the problem is that service "erentpay_db_1" runs and immediately stops. Here is the content of docker-compose-dev.yml file docker-compose-dev.yml version: '2' services: db: build: ./docker/mysql volumes: - ./docker/mysql/data:/var

docker “mysqld: can't read dir of '/etc/mysql/mysql.conf.d' (os errno 2 - no such file or directory)”

你。 提交于 2021-01-04 06:00:10
问题 I have installed docker-engine and docker-compose on my Ubuntu 16.04 machine. When installing docker-engine, I followed: https://www.0x90.it/come-installare-e-usare-docker-su-ubuntu-16-04/ When running the command "docker-compose -f docker-compose-dev.yml up -d", the problem is that service "erentpay_db_1" runs and immediately stops. Here is the content of docker-compose-dev.yml file docker-compose-dev.yml version: '2' services: db: build: ./docker/mysql volumes: - ./docker/mysql/data:/var

docker “mysqld: can't read dir of '/etc/mysql/mysql.conf.d' (os errno 2 - no such file or directory)”

删除回忆录丶 提交于 2021-01-04 05:59:28
问题 I have installed docker-engine and docker-compose on my Ubuntu 16.04 machine. When installing docker-engine, I followed: https://www.0x90.it/come-installare-e-usare-docker-su-ubuntu-16-04/ When running the command "docker-compose -f docker-compose-dev.yml up -d", the problem is that service "erentpay_db_1" runs and immediately stops. Here is the content of docker-compose-dev.yml file docker-compose-dev.yml version: '2' services: db: build: ./docker/mysql volumes: - ./docker/mysql/data:/var

Receive UDP Multicast in Docker Container

耗尽温柔 提交于 2021-01-04 05:52:07
问题 I am using docker compose and hypriotos on a raspberry pi running a node container. I would like to receive udp multicast messages send to 239.255.255.250:1982 in local network. My code is working on other machines outside of docker so I think it's a docker issue. I already exposed port 1982/udp in the docker file and in the docker-compose file I added "1982:1982" and "239.255.255.250:1982:1982/udp" to ports. I still can't receive anything. Am I missing something? My concrete plan is to

Receive UDP Multicast in Docker Container

回眸只為那壹抹淺笑 提交于 2021-01-04 05:48:43
问题 I am using docker compose and hypriotos on a raspberry pi running a node container. I would like to receive udp multicast messages send to 239.255.255.250:1982 in local network. My code is working on other machines outside of docker so I think it's a docker issue. I already exposed port 1982/udp in the docker file and in the docker-compose file I added "1982:1982" and "239.255.255.250:1982:1982/udp" to ports. I still can't receive anything. Am I missing something? My concrete plan is to

stack name with docker-compose

风格不统一 提交于 2021-01-02 05:15:27
问题 Is there a way to set the stack name when using docker-compose? Currently it takes the folder name (which is a horrible area) and that leads to some confusion. For example, we have several projects that have a database folder that contains the database stack. When running these on a single host, we have now several database stacks. 回答1: There are several ways to do it: 1. Using --project-name (or -p ) option when calling docker-compose : docker-compose -p "my-app" up Caution: -p "my-app" must

How to mount docker volume in Azure Web App for containers?

北城以北 提交于 2020-12-31 17:56:33
问题 I'm trying to run KrakenD image in Azure App Service. KrakenD requires json config file krakend.json to be put into /etc/krakend/ ( KrakenD image is based on Linux Alpine ) I created Web App for containers with the following docker-compose file: version: "3" services: krakend: image: devopsfaith/krakend:latest volumes: - ${WEBAPP_STORAGE_HOME}/site/krakend:/etc/krakend ports: - "8080:8080" restart: always Added storage account with a blob container where uploaded sample kraken.json file In