Code Monkey home page Code Monkey logo

Comments (8)

pierreozoux avatar pierreozoux commented on July 4, 2024

Hi,

you mixed arguments to docker run:

  1. you don't need -it
  2. even if you'd need, it is at the wrong place, should be before the image name. (after the image name, it is passed as arguments to the current entrypoint or as a superseed for cmd.
  3. you used the wrong name for the image

This should work:

docker run --name rocketchat --link rocketchatdb -d rocket.chat

If you have a runngin mongodb with the name rocketchatdb. (I close the issue because I'm sure it will solve it ;) )

from docker.official.image.

leandroqm avatar leandroqm commented on July 4, 2024

Unfortunately, it did not solve the issue... :/

docker run --name rocketchat --link rocketchatdb -d rocket.chat

Unable to find image 'rocket.chat:latest' locally
latest: Pulling from library/rocket.chat
709507467581: Pull complete
8c59ab874855: Pull complete
d4f67d857870: Pull complete
e07234a19e6c: Pull complete
10fde2a2f3ee: Pull complete
5a506bbc1b6f: Pull complete
9cc9fdcecba1: Pull complete
02cf92cce9e8: Pull complete
0ab1b987161e: Pull complete
0e1b1f1bb12c: Pull complete
Digest: sha256:719efbb59fd52379b91d294b13b39d8a14b06b3def47e3dd5b160563a423f5ae
Status: Downloaded newer image for rocket.chat:latest
Error response from daemon: Conflict. The name "rocketchat" is already in use by container e7099b4a0723. You have to remove (or rename) that container to be able to reuse that name.

18:17:57  ✘ ⚡  /data 

docker rm rocketchat

rocketchat

18:18:08  ⚡  /data 

docker run --name rocketchat --link rocketchatdb -d rocket.chat

00f79b385934f4620086c0953c5f02036b59b954358c1a3f3bbf21cfb6d89652

18:18:17  ⚡  /data 

docker ps

CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
1582f0c0ac95 mongo "/entrypoint.sh --sma" 22 hours ago Up 22 hours 27017/tcp rocketchatdb

18:18:20  ⚡  /data 

from docker.official.image.

pierreozoux avatar pierreozoux commented on July 4, 2024

Did you read the error message?

Error response from daemon: Conflict. The name "rocketchat" is already in use by container e7099b4a0723. You have to remove (or rename) that container to be able to reuse that name.

It means a container is already running with that name. You need to stop it and remove it first.

I let you read the docker documentation to understand how to do it, and more than anything, to not copy my answer without understanding with the possibility for you to loose data.

from docker.official.image.

leandroqm avatar leandroqm commented on July 4, 2024

I did just that, I removed the container first ... read it again, please.

from docker.official.image.

pierreozoux avatar pierreozoux commented on July 4, 2024

Arf sorry :)

try without the '-d' to see the error in your console.

from docker.official.image.

leandroqm avatar leandroqm commented on July 4, 2024

Error: failed to connect to [db:27017]

maybe the link to rocketchatdb didnt work?

from docker.official.image.

pierreozoux avatar pierreozoux commented on July 4, 2024

yes exactly, make sure your mongo is working well and you can connect to it from another linked container.

Once you are sure of this, please try again and report here.

from docker.official.image.

leandroqm avatar leandroqm commented on July 4, 2024

Using an external mongodb install, it works.
Thank you.

from docker.official.image.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.