-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
34 lines (28 loc) · 1.08 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
FROM base/archlinux:2018.05.01
# Build arguments.
ARG VCS_REF
ARG BUILD_DATE
ARG BRINKOS_VERSION="2018.05.01"
# Labels / Metadata.
LABEL maintainer="James Brink, [email protected]" \
decription="brinkOS" \
version="${BRINKOS_VERSION}" \
org.label-schema.name="brinkos" \
org.label-schema.build-date=$BUILD_DATE \
org.label-schema.vcs-ref=$VCS_REF \
org.label-schema.vcs-url="https://github.com/jamesbrink/brinkos" \
org.label-schema.schema-version="1.0.0-rc1"
# Create user for builds.
RUN set -xe; \
useradd --no-create-home --shell=/bin/false build; \
usermod -L build; \
echo "build ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers; \
echo "root ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers;
# Install all needed deps
RUN set -xe; \
pacman -Syu --noconfirm; \
pacman -S base base-devel cmake automake autoconf wget vim openssh git --noconfirm;
# Copy in our entrypoint and archlive and set ownership.
COPY ./docker-entrypoint.sh /user/local/bin/entrypoint.sh
# Set our entrypoint which kicks off our build.
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]