-
Notifications
You must be signed in to change notification settings - Fork 42
/
Dockerfile
44 lines (35 loc) · 2.04 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
FROM golang:1.19.4
# Switch to archive in sources.list for Debian 9
RUN echo 'deb http://archive.debian.org/debian stretch main contrib non-free' >> /etc/apt/sources.list
RUN apt-get update && apt-get install -y \
cpio \
file \
gcc \
g++ \
libssl1.0-dev \
libxml2-dev \
make \
rpm \
rsyslog \
ruby \
zlib1g-dev \
ruby-dev \
jq
RUN gem install fpm
RUN cd /tmp && wget https://github.com/google/protobuf/releases/download/v2.6.1/protobuf-2.6.1.tar.gz && tar -zxvf protobuf-2.6.1.tar.gz > /dev/null && cd protobuf-2.6.1 && ./configure --prefix=/usr > /dev/null && make > /dev/null && make install > /dev/null && rm -rf /tmp/protobuf-2.6.1 protobuf-2.6.1.tar.gz
# Avoid using ssh to get the repos
#RUN git config --global url."https://github.com/".insteadOf "[email protected]:"
WORKDIR /tmp
# Get dependencies for building hologram
RUN go install github.com/jteeuwen/go-bindata/...
RUN git clone https://github.com/pote/gpm.git && cd gpm && ./configure && make install && rm -rf /tmp/gpm
RUN wget https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/xar/xar-1.5.2.tar.gz && tar xf xar-1.5.2.tar.gz && cd xar-1.5.2 && ./configure && make && make install && rm -rf /tmp/xar-1.5.2
RUN git clone https://github.com/hogliux/bomutils.git > /dev/null && cd bomutils && make > /dev/null && make install > /dev/null && rm -rf /tmp/bomutils
ENV HOLOGRAM_DIR /go/src/github.com/AdRoll/hologram
ENV BUILD_SCRIPTS ${HOLOGRAM_DIR}/buildscripts
ENV PATH ${BUILD_SCRIPTS}:$PATH
ENV BIN_DIR /go/bin
COPY . /go/src/github.com/AdRoll/hologram
WORKDIR /go/src/github.com/AdRoll/hologram
VOLUME ["/go/src/github.com/AdRoll/hologram"]
ENTRYPOINT ["start.sh"]