docker-compose

Docker compose spring boot redis connection issue

試著忘記壹切 提交于 2019-12-12 20:08:08
问题 I am running a simple rest app with redis running in a docker container/docker-compose. I believe, redis must be accessible to spring boot using http://redis:6379 . But, it throws the error: 018-07-22 21:53:33.972 ERROR 1 --- [nio-8080-exec-1] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.springframework.data.redis.RedisConnectionFailureException: Cannot get

MySQL in docker-compose — access denied

岁酱吖の 提交于 2019-12-12 19:35:13
问题 I try to start MySQL server with docker-compose . Here is docker-compose.yaml part: mysql: restart: always image: mysql:latest ports: - "3306:3306" volumes: - /Users/user/Documents/.docker/mysql/config:/etc/mysql/ - /Users/user/Documents/.docker/mysql/data:/var/lib/mysql environment: - MYSQL_ROOT_PASSWORD='123' - MYSQL_ROOT_HOST='172.18.0.1' You see I've specified root password and host as it is said here. Then I try to connect to db (using Intellij Idea if that matters): jdbc:mysql:/

Docker Compose on Windows 7: Could not locate Gemfile or .bundle/ directory

放肆的年华 提交于 2019-12-12 18:37:49
问题 I get the following error when I run the command docker-compose up Could not locate Gemfile or .bundle/ directory exited with code 10 Following is the code. Note : I have added the parent directory of my code as a permanent shared folder to the VM using Oracle VM virtual box manager. Any thoughts to resolve the issue.? Dockerfile FROM ruby:2.3.0 ENV HTTP_PROXY http://proxy.com:8080 ENV HTTPS_PROXY http://proxy.com:8080 RUN mkdir /student-api WORKDIR /student-api ADD Gemfile /student-api

Can't access the Django server at http://127.0.0.1:8000/

↘锁芯ラ 提交于 2019-12-12 18:22:27
问题 At firt time it worked totally fine but it is showing this issue now: app$ python manage.py runserver Performing system checks... System check identified no issues (0 silenced). September 03, 2017 - 17:28:43 Django version 1.11.4, using settings 'aggregator.settings' Starting development server at http://127.0.0.1:8000/ Quit the server with CONTROL-C. It says its running but I can't Access it on that address. What could have been possibly wrong? my docker-compose file: version: "2" services:

How to get started with dockerode

a 夏天 提交于 2019-12-12 17:55:30
问题 I am planning on running my app in docker. I want to dynamically start, stop, build, run commands, ... on docker container. I found a tool named dockerode. Here is the project repos. This project has doc, but I am not understanding very well. I would like to understand few thing. This is how to build an image docker.createContainer({Image: 'ubuntu', Cmd: ['/bin/bash'], name: 'ubuntu-test'}, function (err, container) { container.start(function (err, data) { //... }); }); It is possible to make

Docker-compose wordpress with costum theme + mysql

帅比萌擦擦* 提交于 2019-12-12 17:31:27
问题 I need to do docker-compose: 1)wordpress with my theme 2) mysql. How is this done in practice? And plus one condition, I will fold the .yam file to another person and it should launch in the same way, that is, there was a small problem, I can’t add a topic locally like COPY. / wp-content / There is an idea to create your own wordpress image with the theme and connect it to docker-compose, but there were several unsuccessful attempts, please share a couple of examples of how to deploy

Communication between two microservices by Docker hostname

╄→гoц情女王★ 提交于 2019-12-12 15:55:36
问题 How it works now: Microservice X makes REST API request to Microservice Y with static ip http://{ip-address}:{port}/doSomething The problem: The problem is that I can no long guarantee that static ip. I wan't to solve this by using the docker hostname instead: http://hostname:{port}/doSomething I tried achieving this by creating a used defined network in docker-compose: #part of docker-compose file streamapp: hostname: twitterstreamapp image: twitterstreamapp container_name: twitterstreamapp

Spring Cloud Netflix and Docker Compose - cannot register services with eureka

送分小仙女□ 提交于 2019-12-12 14:49:51
问题 I'm trying to use docker-compose to run 2 simple services locally (Ubuntu): a eureka server, and config server (which is also a eureka client). Both of these have simple dockerfiles that run java -jar , expose their ports, and individually work fine. I also tried to add eureka.client.service-url.defaultZone=http://company-service-discovery:8761/eureka to see if it would register itself, and it worked. My config server cannot successfully register to the eureka server, and I've googled it and

Best practice - Anonymous volume vs bind mount

大城市里の小女人 提交于 2019-12-12 14:17:58
问题 In a container, anonymous volume can be created with syntax( VOLUME /build ) in Dockerfile or below syntax with volumes having /build entry cache: build: ../../ dockerfile: docker/dev/Dockerfile volumes: - /tmp/cache:/cache - /build entrypoint: "true" My understanding is, both approach(above) make volume /build also available after container goes in Exited state. Volume is anonymous because /build points to some random new location(in /var/lib/docker/volumes directory) in docker host I see

Connect from one Docker container to the other one

梦想与她 提交于 2019-12-12 13:41:39
问题 I am running a Java app inside a Docker container which is supposed to connect MySQL inside the other container. Trying multiple options suggested in the forms, nothing really works. Here is my Docker Compose file: version: "3" services: app: build: context: ./ dockerfile: /src/main/docker/Dockerfile image: app1 environment: - DB_HOST=Imrans-MacBook-Pro.local - DB_PORT=3306 ports: - 8080:8080 networks: - backend depends_on: - mysql mysql: image: mysql:5.7.20 hostname: mysql environment: -