-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathDockerfile
More file actions
executable file
·43 lines (35 loc) · 1.11 KB
/
Dockerfile
File metadata and controls
executable file
·43 lines (35 loc) · 1.11 KB
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
#!/bin/echo run with: docker build . -f
# -*- coding: utf-8 -*-
ARG ARCH=arm32v7
ARG TARGET_DEBIAN_ARCH=armhf
FROM docker.io/${ARCH}/debian:stretch AS base
ARG TARGET_DEBIAN_ARCH=armhf
ENV target_debian_arch=${TARGET_DEBIAN_ARCH}
LABEL maintainer="Laudin Molina Troconis <laudin.molinatroconis@silabs.com>"
ENV DEBIAN_FRONTEND=noninteractive
RUN echo "# log: Setup system" \
&& set -x \
&& sed -e 's|\(http://\)\(.*\)\(.debian.org\)|\1archive\3|g' -i /etc/apt/sources.list \
&& sed -e 's|stretch-updates|stretch-proposed-updates|g' -i /etc/apt/sources.list \
&& apt-get update -y \
&& apt-get install -y sudo make \
&& date -u
FROM base AS dev
ENV project=zipgateway
ENV workdir=/usr/local/src/${project}
WORKDIR ${workdir}
COPY helper.mk ${workdir}
RUN echo "# log: Setup dependencies for ${project}" \
&& set -x \
&& ./helper.mk setup/debian/stretch \
&& apt-get autoremove --purge \
&& apt-get clean \
&& date -u
FROM dev AS runtime
COPY . ${workdir}
RUN echo "# log: Build ${project}" \
&& set -x \
&& ./helper.mk \
&& date -u
ENTRYPOINT [ "${workdir}/helper.mk" ]
CMD [ "start", "args=--help"]