-
Notifications
You must be signed in to change notification settings - Fork 5
/
Dockerfile
58 lines (46 loc) · 1.2 KB
/
Dockerfile
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
## Image name: faucet/gnmi
FROM ubuntu:16.04
RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -qy --no-install-recommends \
apt-utils \
ca-certificates \
software-properties-common \
&& add-apt-repository -y ppa:longsleep/golang-backports \
&& apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -qy --no-install-recommends \
fping \
git \
golang-go \
iproute2 \
iputils-ping \
net-tools \
netcat-openbsd \
openssh-client \
psmisc \
sudo \
vim
ENV HOME=/home/faucet
RUN mkdir $HOME
WORKDIR $HOME
COPY ./ .
ENV GOPATH=$HOME/go
ENV GOBIN=$GOPATH/bin
ENV PATH=$GOBIN:${PATH}
RUN mkdir -p \
$GOPATH \
&& go get -u \
github.com/google/gnxi/gnmi_capabilities \
github.com/google/gnxi/gnmi_get \
github.com/google/gnxi/gnmi_set \
github.com/google/gnxi/gnmi_target
RUN go install -v \
github.com/google/gnxi/gnmi_capabilities \
github.com/google/gnxi/gnmi_get \
github.com/google/gnxi/gnmi_set \
github.com/google/gnxi/gnmi_target
RUN cd $HOME/certs/ \
&& ./generate.sh
ENV GNMI_TARGET=localhost
ENV GNMI_PORT=10161
CMD ./_startup.sh \
&& /bin/bash