Skip to content
This repository was archived by the owner on Jan 10, 2020. It is now read-only.

Commit fe9f268

Browse files
committed
Install Docker
1 parent 34eb663 commit fe9f268

File tree

2 files changed

+31
-11
lines changed

2 files changed

+31
-11
lines changed

Diff for: Dockerfile

+10-9
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,21 @@
1-
Dockerfile that contains
1+
# Dockerfile that contains
22
# - Scala
33
# - SBT
44
# - kubectl
55
# - kops
66
# - AWS CLI
7+
# - Docker
78

89
# Pull base image
910
FROM openjdk:8u151
1011

1112
# Environment variables
1213
ENV SCALA_VERSION=2.12.4
1314
ENV SBT_VERSION=1.0.4
14-
ENV KOPS_VERSION=1.7.1
1515
ENV KUBECTL_VERSION=v1.8.3
16+
ENV KOPS_VERSION=1.7.1
1617
ENV HOME=/config
1718

18-
# Download needed libraries
19-
RUN set -x && \
20-
apt-get install -y software-properties-common apt-transport-https && \
21-
curl -fsSL https://download.docker.com/linux/$(. /etc/os-release; echo "$ID")/gpg | apt-key add - && \
22-
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian stretch stable" && \
23-
apt-get update && apt-get install -y docker-ce
24-
2519
# Scala expects this file
2620
RUN touch /usr/lib/jvm/java-8-openjdk-amd64/release
2721

@@ -67,5 +61,12 @@ RUN set -x && \
6761
adduser kubectl -Du 2342 -h /config && \
6862
kubectl version --client
6963

64+
# Install Docker
65+
RUN set -x && \
66+
apt-get install -y software-properties-common apt-transport-https && \
67+
curl -fsSL https://download.docker.com/linux/$(. /etc/os-release; echo "$ID")/gpg | apt-key add - && \
68+
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian stretch stable" && \
69+
apt-get update && apt-get install -y docker-ce
70+
7071
# Define working directory
7172
WORKDIR /root

Diff for: README.md

+21-2
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,36 @@
1-
# Dockerfile with Scala, SBT, Kubernetes and AWS CLI
1+
# Dockerfile with Scala, SBT, Kubernetes, AWS CLI and Docker
22

33
This repository contains **Dockerfile** of:
44
* [Scala](http://www.scala-lang.org)
55
* [sbt](http://www.scala-sbt.org)
66
* [kubectl](https://kubernetes.io/docs/reference/kubectl/overview/)
77
* [kops](https://github.com/kubernetes/kops)
88
* [AWS CLI](https://aws.amazon.com/cli/)
9-
9+
* [Docker](https://www.docker.com/)
1010

1111
## Base Docker Image ##
1212

1313
* [openjdk](https://hub.docker.com/_/openjdk)
1414

15+
## Installation ##
16+
17+
1. Install [Docker](https://www.docker.com)
18+
2. Pull [automated build](https://registry.hub.docker.com/u/moia/scala-sbt-kubernetes-aws-docker) from public [Docker Hub Registry](https://registry.hub.docker.com):
19+
```
20+
docker pull moia/scala-sbt-kubernetes-aws-docker
21+
```
22+
Alternatively, you can build an image from Dockerfile:
23+
```
24+
docker build -t moia/scala-sbt-kubernetes-aws-docker github.com/moia-dev/scala-sbt-kubernetes-aws-docker
25+
```
26+
27+
28+
## Usage ##
29+
30+
```
31+
docker run -it --rm moia/scala-sbt-kubernetes-aws-docker
32+
```
33+
1534
## License ##
1635

1736
This code is open source software licensed under the [Apache 2.0 License]("http://www.apache.org/licenses/LICENSE-2.0.html").

0 commit comments

Comments
 (0)