We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2bf1ed5 commit 4a0ae0dCopy full SHA for 4a0ae0d
scripts/docker/ubuntu-homebrew.Dockerfile
@@ -0,0 +1,18 @@
1
+FROM ubuntu:20.04
2
+
3
+RUN apt-get update -y && apt-get install -y build-essential curl sudo git && \
4
+ useradd -m user && echo "user:user" | chpasswd && adduser user sudo
5
+USER user
6
+RUN /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
7
+USER root
8
+RUN echo '#!/usr/bin/env bash\neval $(/home/user/.linuxbrew/bin/brew shellenv)\nbrew ${@:1}' > /usr/bin/brew
9
+RUN chmod +x /usr/bin/brew
10
11
+RUN brew tap mongodb/brew
12
+RUN brew install mongosh
13
14
+RUN echo '#!/usr/bin/env bash\neval $(/home/user/.linuxbrew/bin/brew shellenv)\nmongosh ${@:1}' > /usr/bin/mongosh
15
+RUN chmod +x /usr/bin/mongosh
16
17
18
+ENTRYPOINT [ "mongosh" ]
0 commit comments