-
Notifications
You must be signed in to change notification settings - Fork 17
/
Layerfile
33 lines (28 loc) · 1.01 KB
/
Layerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM vm/ubuntu:18.04
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates curl g++ gcc libc6-dev make pkg-config \
apt-transport-https gnupg-agent software-properties-common && \
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - && \
sudo add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) \
stable" && \
apt-get update && \
apt-get install -y docker-ce docker-ce-cli containerd.io
# install go
RUN curl -L "https://golang.org/dl/go1.13.linux-amd64.tar.gz" |\
tar -C /usr/local -xzf /dev/stdin
ENV GOPATH=/go
ENV PATH=$GOPATH/bin:/usr/local/go/bin:$PATH
ENV GO111MODULE=on
WORKDIR /app
COPY . ./
CACHE ~/.cache /go/pkg/mod
RUN bash ./build.sh
COPY example /example
WORKDIR /example/timestamp-as-a-service
# TODO HACK: see issue #8
RUN mkdir -p ~/.kube && touch ~/.kube/sanic.io.config
RUN sanic env dev sanic run print_env | grep "in dev!"
RUN sanic env dev sanic build