docker-for-mac

JHipster application in docker container cannot be accessed on host network, cannot communicate with other containers on non-host network

余生颓废 提交于 2020-01-24 22:23:09
问题 I am trying to deploy my JHipster microservices and registry in docker containers on my OS X development machine. I deploy the registry using more or less the default docker-compose configuration JHipster provides out of the box: version: '2' services: jhipster-registry: image: jhipster/jhipster-registry:v3.1.0 volumes: - ./central-server-config:/central-config # When run with the "dev" Spring profile, the JHipster Registry will # read the config from the local filesystem (central-server

docker swarm init could not choose an IP address error

只谈情不闲聊 提交于 2020-01-01 04:03:09
问题 Experimenting with Docker Swarm with Docker Desktop for Mac . I tried this: docker-machine create -d virtualbox node-1 docker-machine create -d virtualbox node-2 docker-machine create -d virtualbox node-3 eval $(docker-machine env node-1) docker swarm init \ --secret my-secret \ --auto-accept worker \ --listen-addr $(docker-machine ip node-1):2377 The last command ( docker swarm init ) returns this error: Error response from daemon: could not choose an IP address to advertise since this

Linked docker-compose containers making http requests

*爱你&永不变心* 提交于 2019-12-31 05:03:25
问题 I've been looking on the web for a while and haven't found a solution to my problem which is similar to this StackOverflow question Docker HTTP-requests between containers. But this answer is already what I'm doing in my computer. I'm providing my docker-compose file version: "3" services: web: image: ecdavis15/tsn-web-server ports: - "3000:3000" links: - app app: image: ecdavis15/tsn-app-server ports: - "3030:3030" links: - mongo mongo: image: mongo ports: - "27017:27017" volumes: - ./data

Is there a workaround to use the host's network in Docker for Mac?

非 Y 不嫁゛ 提交于 2019-12-23 19:40:45
问题 Since Docker for Mac does not use Virtualbox but rather uses xhyve there is no straightforward way to access my mac's network (specifically for VPN and network attached devices) using network_mode: host or --network host . I've searched and searched but have found no simple workaround. The best solution I've figured out is to run a Linux virtualbox then install docker on that and execute docker-compose up or docker run in there. Not ideal at all. 回答1: This doesn't seem to be possible. There

Disable autostart of docker-compose project

做~自己de王妃 提交于 2019-12-23 06:47:14
问题 I have a docker-compose project using Docker for Mac that autostarts when I boot the computer. I usually start the project with docker-compose up -d , but even running docker-compose stop before shutting down autostarts it again on boot. I am not aware of specifically enabling this. How can I disable it? 回答1: Today I had the same issue that all containers are started when I boot my dev laptop, as restart: always was set in the .yml files. As I don't want to touch the .yml files, I just found

Docker run failed with Error response from daemon

那年仲夏 提交于 2019-12-19 02:47:07
问题 I simply run the following command: docker run -d -p 80:80 --name webserver nginx and after pulling all images returns this error: docker: Error response from daemon: driver failed programming external connectivity on endpoint webserver (ac5719bc0e95ead1a4ec6b6ae437c4c0b8a9600ee69ecf72e73f8d2d12020f97): Error starting userland proxy: Bind for 0.0.0.0:80: unexpected error (Failure EADDRINUSE). Here is my docker Version info: Client: Version: 1.12.0 API version: 1.24 Go version: go1.6.3 Git

Is there any way to enable Kubernetes on Docker for Mac via terminal?

前提是你 提交于 2019-12-11 21:32:08
问题 I'm developing an Electron app and want to distribute the back-end portion of the web application (PHP) via Docker and Kubernetes (using Helm charts). I plan to package the expanded dmg of Docker, but haven't found a way to configure Docker from terminal. Is this possible - enable Kubernetes and increase CPU size and RAM via terminal? Edit: I don't want to just start Docker from the command line. I want to configure the first installation as well specifying the amount of resources the Docker

Docker for Mac(Edge) - Kubernetes - LoadBalancer

我是研究僧i 提交于 2019-12-11 12:11:03
问题 It is so cool that we have a LoadBalancer in Docker for Mac. I have a question regarding ports created: apiVersion: v1 kind: Service metadata: name: nginx labels: run: nginx spec: ports: port: 9999 targetPort: 80 selector: run: nginx type: LoadBalancer This gives me(kubectl get service): nginx LoadBalancer 10.96.128.253 localhost 9999:32455/TCP 2s What is 32455 ? Thanks 回答1: 32455 is your nodePort. Kubernetes automatically assigns a unique nodePort for any service that is accessible outside

Exposing a TTY device in a docker container with docker for mac

倖福魔咒の 提交于 2019-12-11 08:42:06
问题 I'm trying to expose an Arduino that's plugged into my mac to a linux instance I'm running in Docker for Mac (no vm). The Arduino exposes itself as /dev/tty.usbserialXXX . I'm using the node docker image which is based upon ubuntu. The command I'm running is $ docker run --rm -it -v `pwd`:/app --device /dev/tty.usbmodem1421 node bash docker: Error response from daemon: linux runtime spec devices: error gathering device information while adding custom device "/dev/tty.usbmodem1421": lstat /dev

Slowness in Docker container

拜拜、爱过 提交于 2019-12-11 04:58:11
问题 I'm using docker for mac and curl command from docker container takes way longer than from my mac. Container is using default bridge network. See below curl command from inside the container: Command from mac: Thanks. 回答1: It is a known issue that networking with bridge / nat mode in docker is slow. You could use hosted mode. This should be solved by the macvlan driver. For further reference, please look at this bug. 回答2: This is known and solved in different ways, please see those benchmarks