Skip to content

Commit 616c1b5

Browse files
author
Misty Stanley-Jones
authored
Add step to install software-properties-common (docker#2523)
This is needed for the `lsb_release` command that is used further down the Dockerfile. Fixes docker#424.
1 parent d611a12 commit 616c1b5

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

engine/examples/mongodb.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ a MongoDB repository file for the package manager.
6363
# Installation:
6464
# Import MongoDB public GPG key AND create a MongoDB list file
6565
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv EA312927
66+
RUN apt-get install --no-install-recommends software-properties-common
6667
RUN echo "deb http://repo.mongodb.org/apt/ubuntu $(cat /etc/lsb-release | grep DISTRIB_CODENAME | cut -d= -f2)/mongodb-org/3.2 multiverse" | tee /etc/apt/sources.list.d/mongodb-org-3.2.list
6768
```
6869

@@ -74,8 +75,9 @@ RUN apt-get update && apt-get install -y mongodb-org
7475
```
7576

7677
> **Tip**: You can install a specific version of MongoDB by using a list of required packages with versions, e.g.:
77-
```dockerfile
78-
RUN apt-get update && apt-get install -y mongodb-org=3.0.1 mongodb-org-server=3.0.1 mongodb-org-shell=3.0.1 mongodb-org-mongos=3.0.1 mongodb-org-tools=3.0.1
78+
>
79+
> ```dockerfile
80+
> RUN apt-get update && apt-get install -y mongodb-org=3.0.1 mongodb-org-server=3.0.1 mongodb-org-shell=3.0.1 mongodb-org-> mongos=3.0.1 mongodb-org-tools=3.0.1
7981
```
8082
8183
MongoDB requires a data directory. Let's create it as the final step of our

0 commit comments

Comments
 (0)