Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker install error #1

Closed
lapin7 opened this issue Aug 12, 2015 · 5 comments
Closed

Docker install error #1

lapin7 opened this issue Aug 12, 2015 · 5 comments

Comments

@lapin7
Copy link

lapin7 commented Aug 12, 2015

The command

$docker pull synereo/synereo

works well. But the directory "synereo" is not created. So the build cannot be done.

Cheers, HJ

@yuvadm
Copy link
Contributor

yuvadm commented Aug 12, 2015

@lapin7 if you pulled the image you don't need to build it ;)

@yuvadm yuvadm closed this as completed Aug 12, 2015
@yuvadm
Copy link
Contributor

yuvadm commented Aug 12, 2015

@lapin7 If you think the README needs clarification on this point, please open a pull request!

@lapin7
Copy link
Author

lapin7 commented Aug 13, 2015

Hi Yuval,

I made some progress. I run this on a MacBook Pro. I can provide further details if necessary.
In Italic you find some comments. All the commands are written down. Now my attempts end in Scala with an error:
:17: error: not found: value setupAndRunTest
In the instructions it helps maybe if you:

  • add the feedback when you run a command.
  • separate the commands to add in terminal 1 and terminal 2.
  • add a command for setting the RabbitMQ port by using the -p 5672:5672

bash-3.2$ docker pull synereo/synereo
# And it downloaded
bash-3.2$ mkdir synereo
# I don’t think this directory is created by a program
bash-3.2$ cd synereo
#
bash-3.2$ docker build -t synereo/synereo .
# FATA[0000] Cannot locate Dockerfile: Dockerfile
# But in your mail you said that you don’t have to build the image
# because the image is already there
bash-3.2$ docker images
REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE
synereo/synereo latest ff0f492771b5 2 weeks ago 734.5 MB
# So I run synereo/synereo
bash-3.2$ docker run -it synereo/synereo /bin/bash
# gives me another root
root@ce6af0844445:/# java -version
java version "1.7.0_79"
OpenJDK Runtime Environment (IcedTea 2.5.5) (7u79-2.5.5-1~deb8u1)
OpenJDK 64-Bit Server VM (build 24.79-b02, mixed mode)
#
root@ce6af0844445:/# scala -version
Scala code runner version 2.10.5 -- Copyright 2002-2013, LAMP/EPFL
#
root@ce6af0844445:/# sbt -version
[info] Set current project to root (in build file:/)
[warn] The - command is deprecated in favor of onFailure and will be removed in 0.14.0
#

Testing rabbitmq

bash-3.2$ docker run -d --hostname rabbit1 --name test-rabbit1 -e RABBIT_ERLANG_COOKIE='s3cr3t' rabbitmq
Unable to find image 'rabbitmq:latest' locally
Pulling repository rabbitmq
#
FATA[0045] Get https://index.docker.io/v1/repositories/library/rabbitmq/images: dial tcp: lookup index.docker.io on 192.168.178.1:53: read udp 192.168.178.1:53: i/o timeout
# This is because my Mac connected through another network (at work)
bash-3.2$ boot2docker down
bash-3.2$ boot2docker up
bash-3.2$ docker run -d --hostname rabbit1 --name test-rabbit1 -e RABBIT_ERLANG_COOKIE='s3cr3t' rabbitmq
Unable to find image 'rabbitmq:latest' locally
# I didn’t pull rabbitmq before, but it does it now by executing the script
latest: Pulling from rabbitmq
4c8cbfd2973e: Pull complete
60c52dbe9d91: Pull complete
6387f16409ea: Pull complete
3445f579ce26: Pull complete
787a16fd97f3: Pull complete
cb7ce70aa19f: Pull complete
bcea54d1cc39: Pull complete
871ab89700a8: Pull complete
600fc5e9a1d9: Pull complete
34ef06a9cb95: Pull complete
7a1727f341bd: Pull complete
40915e9cc7a2: Pull complete
29de71ada8f9: Pull complete
d214188f90e0: Pull complete
85e8c6c4c319: Pull complete
24303685e53d: Pull complete
5a71837ecf36: Pull complete
7be5a726e21e: Pull complete
5db034d1cfa4: Pull complete
f2e68423beb7: Pull complete
6b446c300bd7: Pull complete
a06b2227c259: Pull complete
Digest: sha256:7a4153fb4192e9d427a4052529486afd60e39dfd81537c381998da2202cd22b1
Status: Downloaded newer image for rabbitmq:latest
97bf5157d039b44b287513b1868096650fba33e6aad6bfefbdb6260771318cd5
# The download went fine
bash-3.2$ docker images
REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE
rabbitmq latest a06b2227c259 2 weeks ago 143.7 MB
synereo/synereo latest ff0f492771b5 2 weeks ago 734.5 MB
bash-3.2$ docker run -d --hostname rabbit1 --name test-rabbit1 -e RABBIT_ERLANG_COOKIE='s3cr3t' rabbitmq
FATA[0000] Error response from daemon: Conflict. The name "test-rabbit1" is already in use by container 97bf5157d039. You have to delete (or rename) that container to be able to reuse that name.

bash-3.2$ docker stop test-rabbit1
test-rabbit1

bash-3.2$ docker rm test-rabbit1
test-rabbit1
# Now the container test-rabbit1 is stopped and deleted

bash-3.2$ docker run -d --hostname rabbit1 --name test-rabbit1 -e RABBIT_ERLANG_COOKIE='s3cr3t' rabbitmq
6e2e2e35b77945213ae7e1e01c10c08c5443607dbb696e316867fb53657a77d8

bash-3.2$ docker run -d --hostname rabbit2 --name test-rabbit2 -e RABBIT_ERLANG_COOKIE='s3cr3t' rabbitmq
3666e25f721e285a288eccb6e57ea5e28e98b263db6e6b662d7c302d57e12e81

Testing rabbitmq on two terminals

terminal 1
bash-3.2$ docker run --name synereo1 --link test-rabbit1:rabbit -it synereo/synereo /bin/bash
root@c675935fc516:/# echo RABBIT_PORT
RABBIT_PORT
# No IP-number appeared
# I didn’t know how to set the RabbitMQ port by using the -p 5672:5672
root@c675935fc516:/# cd /app/strategies-master
root@c675935fc516:/app/strategies-master# sbt console
[info] Loading project definition from /app/strategies-master/project
[info] Set current project to strategies (in build file:/app/strategies-master/)
[info] Starting scala interpreter...
[info]
Welcome to Scala version 2.10.2 (OpenJDK 64-Bit Server VM, Java 1.7.0_79).
Type in expressions to have them evaluated.
Type :help for more information.

scala> import java.net.URI
import java.net.URI

scala> import com.biosimilarity.lift.lib._
import com.biosimilarity.lift.lib._

scala> import root.com.rabbitmq.client.{Channel=>RabbitChan, _}
import root.com.rabbitmq.client.{Channel=>RabbitChan, _}

scala> val srcHost1 = new URI( "amqp://guest:guest@172.17.0.1:5672/synereo" )
srcHost1: java.net.URI = amqp://guest:guest@172.17.0.1:5672/synereo

scala> val trgtHost1 = new URI( "amqp://guest:guest@172.17.0.2:5672/synereo" )
trgtHost1: java.net.URI = amqp://guest:guest@172.17.0.2:5672/synereo

scala> setupAndRunTest( true, srcHost1, trgtHost1, "synereo1", true, 10 )
:17: error: not found: value setupAndRunTest
setupAndRunTest( true, srcHost1, trgtHost1, "synereo1", true, 10 )
^

scala>

terminal 2
bash-3.2$ docker run --name synereo2 --link test-rabbit2:rabbit -it synereo/synereo /bin/bash
root@a0b4f5d88c7f:/# echo RABBIT_PORT
RABBIT_PORT
# No IP-number appeared
# I didn’t know how to set the RabbitMQ port by using the -p 5672:5672
root@a0b4f5d88c7f:/# cd /app/strategies-master
root@a0b4f5d88c7f:/app/strategies-master# sbt console
[info] Loading project definition from /app/strategies-master/project
[info] Set current project to strategies (in build file:/app/strategies-master/)
[info] Starting scala interpreter...
[info]
Welcome to Scala version 2.10.2 (OpenJDK 64-Bit Server VM, Java 1.7.0_79).
Type in expressions to have them evaluated.
Type :help for more information.

scala> import java.net.URI
import java.net.URI

scala> import com.biosimilarity.lift.lib._
import com.biosimilarity.lift.lib._

scala> import root.com.rabbitmq.client.{Channel=>RabbitChan, _}
import root.com.rabbitmq.client.{Channel=>RabbitChan, _}

scala> val srcHost1 = new URI( "amqp://guest:guest@172.17.0.1:5672/synereo" )
srcHost1: java.net.URI = amqp://guest:guest@172.17.0.1:5672/synereo

scala> val trgtHost1 = new URI( "amqp://guest:guest@172.17.0.2:5672/synereo" )
trgtHost1: java.net.URI = amqp://guest:guest@172.17.0.2:5672/synereo

scala> setupAndRunTest( false, srcHost1, trgtHost1, "synereo1", true, 10 )
:17: error: not found: value setupAndRunTest
setupAndRunTest( false, srcHost1, trgtHost1, "synereo1", true, 10 )
^

scala>

Best regards,
Henk

On 12 Aug 2015, at 17:24, Yuval Adam notifications@github.com wrote:

@lapin7 https://github.com/lapin7 if you pulled the image you don't need to build it ;)


Reply to this email directly or view it on GitHub #1 (comment).

@yuvadm
Copy link
Contributor

yuvadm commented Aug 13, 2015

@lapin7 nice progress! Although next time you can just paste the error with some of the preceding lines, no need for the entire history :)

As for your problem, this is due to a missing import, you'll need to run:

import com.biosimilarity.lift.lib.usage.AMQPTPSample._

I'll add this now to the README.

@lapin7
Copy link
Author

lapin7 commented Aug 13, 2015

Hi Yuval,

Thanks. And again I’m a bit further but have not reached the final “successful”.
Italic are previous commands. Red is error.

Consolel 1

scala> import java.net.URI
import java.net.URI

scala> import com.biosimilarity.lift.lib._
import com.biosimilarity.lift.lib._

scala> import root.com.rabbitmq.client.{Channel=>RabbitChan, _}
import root.com.rabbitmq.client.{Channel=>RabbitChan, _}

scala> import com.biosimilarity.lift.lib.usage.AMQPTPSample._
import com.biosimilarity.lift.lib.usage.AMQPTPSample._

scala> val srcHost1 = new URI( "amqp://guest:guest@172.17.0.1:5672/synereo" )
srcHost1: java.net.URI = amqp://guest:guest@172.17.0.1:5672/synereo

scala> val trgtHost1 = new URI( "amqp://guest:guest@172.17.0.2:5672/synereo" )
trgtHost1: java.net.URI = amqp://guest:guest@172.17.0.2:5672/synereo

scala> setupAndRunTest( true, srcHost1, trgtHost1, "synereo1", true, 10 )
java.net.NoRouteToHostException: No route to host
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
…..

Consolel 2

scala> import java.net.URI
import java.net.URI

scala> import com.biosimilarity.lift.lib._
import com.biosimilarity.lift.lib._

scala> import root.com.rabbitmq.client.{Channel=>RabbitChan, _}
import root.com.rabbitmq.client.{Channel=>RabbitChan, _}

scala> import com.biosimilarity.lift.lib.usage.AMQPTPSample._
import com.biosimilarity.lift.lib.usage.AMQPTPSample._

scala> val srcHost1 = new URI( "amqp://guest:guest@172.17.0.1:5672/synereo" )
srcHost1: java.net.URI = amqp://guest:guest@172.17.0.1:5672/synereo

scala> val trgtHost1 = new URI( "amqp://guest:guest@172.17.0.2:5672/synereo" )
trgtHost1: java.net.URI = amqp://guest:guest@172.17.0.2:5672/synereo

scala> setupAndRunTest( false, srcHost1, trgtHost1, "synereo1", true, 10 )
java.net.NoRouteToHostException: No route to host
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)

On 13 Aug 2015, at 12:08, Yuval Adam notifications@github.com wrote:

@lapin7 https://github.com/lapin7 nice progress! Although next time you can just paste the error with some of the preceding lines, no need for the entire history :)

As for your problem, this is due to a missing import, you'll need to run:

import com.biosimilarity.lift.lib.usage.AMQPTPSample._
I'll add this now to the README.


Reply to this email directly or view it on GitHub #1 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants