-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
52 lines (46 loc) · 1.39 KB
/
Dockerfile
File metadata and controls
52 lines (46 loc) · 1.39 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
44
45
46
47
48
49
50
51
52
# Download base image
FROM alpine:3.8
# Define the ARG variables
ARG VERSION
ARG BUILD_DATE
ARG VCS_REF
ARG OVERLAY_VERSION=v1.21.4.0
ARG OVERLAY_ARCH=amd64
# Labels
LABEL org.label-schema.name="Alpine base docker image" \
org.label-schema.description="This is an Alpine base docker image with s6-overlay" \
org.label-schema.vendor="Paul NOBECOURT <paul.nobecourt@orange.fr>" \
org.label-schema.url="https://github.com/pnobecourt/" \
org.label-schema.version=$VERSION \
org.label-schema.build-date=$BUILD_DATE \
org.label-schema.vcs-url="https://github.com/pnobecourt/docker-alpine-s6" \
org.label-schema.vcs-ref=$VCS_REF \
org.label-schema.schema-version="1.0"
# Define the ENV variables
ENV LANG=C.UTF-8 \
SHELL=/bin/bash \
TERM=xterm \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
PS1=$(whoami)@$(hostname):$(pwd)$
# Install tools and s6-overlay
RUN apk update && \
apk add --no-cache \
bash \
ca-certificates \
coreutils \
curl \
grep \
less \
logrotate \
nano \
shadow \
sudo \
tzdata \
wget \
&& \
curl -L -S https://github.com/just-containers/s6-overlay/releases/download/$OVERLAY_VERSION/s6-overlay-$OVERLAY_ARCH.tar.gz | tar xvz -C / && \
rm -rf /var/cache/apk/*
# Add files
ADD /root /
# Entrypoint
ENTRYPOINT [ "/init" ]