boot2docker

Connecting to MySQL Server on localhost through Docker

淺唱寂寞╮ 提交于 2020-01-13 05:49:12
问题 So, I'm able to generally contact my localhost through Docker by running a container with --add-host=localbox:192.168.59.3 . ping localbox works just fine. Problem is, I can't seem to be able to even get a response from MySQL Server. mysql -h localbox , which works fine from outside of the docker container, just gets me ERROR 2003 (HY000): Can't connect to MySQL server on 'localbox' (111) from within. I've done GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'password' WITH GRANT

Specifying superuser PostgreSQL password for a Docker Container

你离开我真会死。 提交于 2020-01-12 14:03:16
问题 When running a PostgreSQL database in a Docker container, the documentation for the official PostgreSQL Docker Image specifies that the administrator password should be set in an environmental variable like: docker run --name some-postgres -e POSTGRES_PASSWORD=mysecretpassword -d postgres For those that do not want to hard-code a plain-text password in their scripts, are there more secure options to consider? 回答1: Injecting configuration settings as environment variables is the approach to

pushing docker image to dockerhub

拈花ヽ惹草 提交于 2020-01-11 17:45:24
问题 I ve created my own docker file ( that runs a shell script which prints "helloworld"). The image is "hellodocker" and the tag is "mytag" I now have: bash-3.2$ docker images REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE hellodocker mytag 3514c8dc11a8 39 minutes ago 2.433 MB busybox buildroot-2013.08.1 d200959a3e91 10 weeks ago 2.489 MB busybox ubuntu-14.04 37fca75d01ff 10 weeks ago 5.609 MB busybox ubuntu-12.04 fd5373b3d938 10 weeks ago 5.455 MB busybox buildroot-2014.02 a9eb17255234 10 weeks

pushing docker image to dockerhub

荒凉一梦 提交于 2020-01-11 17:44:38
问题 I ve created my own docker file ( that runs a shell script which prints "helloworld"). The image is "hellodocker" and the tag is "mytag" I now have: bash-3.2$ docker images REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE hellodocker mytag 3514c8dc11a8 39 minutes ago 2.433 MB busybox buildroot-2013.08.1 d200959a3e91 10 weeks ago 2.489 MB busybox ubuntu-14.04 37fca75d01ff 10 weeks ago 5.609 MB busybox ubuntu-12.04 fd5373b3d938 10 weeks ago 5.455 MB busybox buildroot-2014.02 a9eb17255234 10 weeks

Port forwarding in docker-machine?

一世执手 提交于 2020-01-09 03:01:04
问题 Since boot2docker is deprecated I've switched to docker-machine but I don't know how to open a port from docker-machine . In boot2docker I could do like this: boot2docker ssh -L 27017:localhost:27017 This would forward port 27017 from VirtualBox to localhost 27017 as long as the SSH connection is open. Note that I'm not looking for a way to open the port permanently in VirtualBox. How can I achieve this with docker-machine ? 回答1: You can still access the VBoxmanage.exe command from the

How to enable docker remote api rest in mac OS X with boot2docker?

霸气de小男生 提交于 2020-01-06 03:34:27
问题 I'm new to docker. I want to use docker remote api, But I failed. Firstly, I use the docker-java that is Remote API client libraries. It throws Exception is: The server failed to respond with a valid HTTP response more detail is here.So, I want to know what is wrong about it. I use the remote rest api to connect my docker from this tutorial. But it didn't work yet. I use the command: curl -v http://192.168.59.103:2376/info and show me this information: * Hostname was NOT found in DNS cache *

Docker on windows: data in mounted volume doesn't updated

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-06 03:17:30
问题 I run docker on windows 10 with this command: docker run -d -v /c/Users/tsh/docker:/usr/share/nginx/html -p 80:80 nginx Inside Users/tsh/docker folder I have simple index.html file: <h1>Hello!</h1> It works perfectly well, when I point my browser on windows to virtualbox IP I can see web page with "Hello!" displayed. But when I change content of the index.html to something like: <h1>Hello from docker!</h1> The web page still shows me the old "Hello!" text. Is it possible when I change index

Slow network performance in Docker container

非 Y 不嫁゛ 提交于 2020-01-05 04:27:11
问题 I'm running the latest docker/ docker-machine on OSX Yosemite and VirtualBox and I'm trying to connect to a lein ring server running in a container from the host the loading is slow as in like Load time is over 1 min The following is my configuration Docker 1.12.0 Docker Machine 0.8.0 VirtualBox 5.0.24 My Docker Machine "ConfigVersion": 3, "Driver": { "IPAddress": "192.168.99.100", "MachineName": "default", "SSHUser": "docker", "SSHPort": 49478, "SSHKeyPath": "/Volumes/NASMAC/VMs/.docker

Xdebug can't connect back to Docker host

我怕爱的太早我们不能终老 提交于 2020-01-03 21:13:33
问题 I've just setup Docker on my machine & have an Nginx/PHP7 (FPM)/MySQL setup all working fine, but having installed Xdebug on the PHP container I can't get it to connect back to PHPStorm on my host machine. Here's my PHP Xdebug config… zend_extension=/usr/local/lib/php/extensions/no-debug-non-zts- 20151012/xdebug.so xdebug.remote_log=/usr/local/var/log/xdebug.log xdebug.remote_enable=1 xdebug.remote_host=192.168.99.1 xdebug.remote_port=9000 xdebug.remote_connect_back=1 xdebug.remote_handler

Xdebug can't connect back to Docker host

时光毁灭记忆、已成空白 提交于 2020-01-03 21:13:01
问题 I've just setup Docker on my machine & have an Nginx/PHP7 (FPM)/MySQL setup all working fine, but having installed Xdebug on the PHP container I can't get it to connect back to PHPStorm on my host machine. Here's my PHP Xdebug config… zend_extension=/usr/local/lib/php/extensions/no-debug-non-zts- 20151012/xdebug.so xdebug.remote_log=/usr/local/var/log/xdebug.log xdebug.remote_enable=1 xdebug.remote_host=192.168.99.1 xdebug.remote_port=9000 xdebug.remote_connect_back=1 xdebug.remote_handler