Skip to content
This repository was archived by the owner on Feb 16, 2023. It is now read-only.

Commit 664de7c

Browse files
authored
Merge pull request #4 from linuxserver/alpine-dev
Release alpine images
2 parents 6943966 + 9c7be25 commit 664de7c

File tree

8 files changed

+149
-99
lines changed

8 files changed

+149
-99
lines changed

Dockerfile

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,32 +2,38 @@ ARG DOCKER_VERSION=19.03.8
22

33
FROM docker:${DOCKER_VERSION} AS docker-cli
44

5-
FROM lsiobase/ubuntu:bionic AS build
5+
FROM lsiobase/alpine:3.12 AS build
66

77
ARG COMPOSE_VERSION
88

9-
RUN apt-get update && apt-get install --no-install-recommends -y \
9+
RUN \
10+
apk add --no-cache \
11+
bash \
12+
build-base \
13+
ca-certificates \
1014
curl \
1115
gcc \
1216
git \
1317
libc-dev \
1418
libffi-dev \
15-
libgcc-6-dev \
16-
libssl-dev \
19+
libgcc \
1720
make \
21+
musl-dev \
1822
openssl \
23+
openssl-dev \
1924
python3-dev \
20-
python3-pip \
21-
zlib1g-dev
25+
py3-pip \
26+
zlib-dev
2227

2328
COPY --from=docker-cli /usr/local/bin/docker /usr/local/bin/docker
2429

2530
RUN \
2631
mkdir -p /compose && \
2732
if [ -z ${COMPOSE_VERSION+x} ]; then \
2833
COMPOSE_VERSION=$(curl -sX GET "https://api.github.com/repos/docker/compose/releases/latest" \
29-
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
34+
| awk '/tag_name/{print $4;exit}' FS='[""]' | awk '$0="alpine-"$0'); \
3035
fi && \
36+
COMPOSE_VERSION=$(echo "$COMPOSE_VERSION" | sed 's|alpine-||') && \
3137
git clone https://github.com/docker/compose.git && \
3238
cd /compose && \
3339
git checkout "${COMPOSE_VERSION}" && \
@@ -40,6 +46,13 @@ RUN \
4046
chmod 777 dist && \
4147
/compose/.tox/${PY_ARG}/bin/pip3 install -q -r requirements-build.txt && \
4248
echo "$(script/build/write-git-sha)" > compose/GITSHA && \
49+
PYINSTVER=$(cat requirements-build.txt | grep pyinstaller | sed 's|pyinstaller==|v|') && \
50+
git clone --single-branch --branch develop https://github.com/pyinstaller/pyinstaller.git /tmp/pyinstaller && \
51+
cd /tmp/pyinstaller/bootloader && \
52+
git checkout $(PYINSTVER) && \
53+
/compose/.tox/${PY_ARG}/bin/python3 ./waf configure --no-lsb all && \
54+
/compose/.tox/${PY_ARG}/bin/pip3 install .. && \
55+
cd /compose && \
4356
export PATH="/compose/pyinstaller:${PATH}" && \
4457
/compose/.tox/${PY_ARG}/bin/pyinstaller --exclude-module pycrypto --exclude-module PyInstaller docker-compose.spec && \
4558
ls -la dist/ && \
@@ -48,7 +61,7 @@ RUN \
4861
docker-compose version
4962

5063
############## runtime stage ##############
51-
FROM lsiobase/ubuntu:bionic
64+
FROM lsiobase/alpine:3.12
5265

5366
ARG BUILD_DATE
5467
ARG VERSION

Dockerfile.aarch64

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,39 @@
11
ARG DOCKER_VERSION=19.03.8
22

3-
FROM arm64v8/docker:${DOCKER_VERSION} AS docker-cli
3+
FROM docker:${DOCKER_VERSION} AS docker-cli
44

5-
FROM lsiobase/ubuntu:arm64v8-bionic AS build
5+
FROM lsiobase/alpine:arm64v8-3.12 AS build
66

77
ARG COMPOSE_VERSION
88

9-
RUN apt-get update && apt-get install --no-install-recommends -y \
9+
RUN \
10+
apk add --no-cache \
11+
bash \
12+
build-base \
13+
ca-certificates \
1014
curl \
1115
gcc \
1216
git \
1317
libc-dev \
1418
libffi-dev \
15-
libgcc-6-dev \
16-
libssl-dev \
19+
libgcc \
1720
make \
21+
musl-dev \
1822
openssl \
23+
openssl-dev \
1924
python3-dev \
20-
python3-pip \
21-
zlib1g-dev
25+
py3-pip \
26+
zlib-dev
2227

2328
COPY --from=docker-cli /usr/local/bin/docker /usr/local/bin/docker
2429

2530
RUN \
2631
mkdir -p /compose && \
2732
if [ -z ${COMPOSE_VERSION+x} ]; then \
2833
COMPOSE_VERSION=$(curl -sX GET "https://api.github.com/repos/docker/compose/releases/latest" \
29-
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
34+
| awk '/tag_name/{print $4;exit}' FS='[""]' | awk '$0="alpine-"$0'); \
3035
fi && \
36+
COMPOSE_VERSION=$(echo "$COMPOSE_VERSION" | sed 's|alpine-||') && \
3137
git clone https://github.com/docker/compose.git && \
3238
cd /compose && \
3339
git checkout "${COMPOSE_VERSION}" && \
@@ -40,6 +46,13 @@ RUN \
4046
chmod 777 dist && \
4147
/compose/.tox/${PY_ARG}/bin/pip3 install -q -r requirements-build.txt && \
4248
echo "$(script/build/write-git-sha)" > compose/GITSHA && \
49+
PYINSTVER=$(cat requirements-build.txt | grep pyinstaller | sed 's|pyinstaller==|v|') && \
50+
git clone --single-branch --branch develop https://github.com/pyinstaller/pyinstaller.git /tmp/pyinstaller && \
51+
cd /tmp/pyinstaller/bootloader && \
52+
git checkout $(PYINSTVER) && \
53+
/compose/.tox/${PY_ARG}/bin/python3 ./waf configure --no-lsb all && \
54+
/compose/.tox/${PY_ARG}/bin/pip3 install .. && \
55+
cd /compose && \
4356
export PATH="/compose/pyinstaller:${PATH}" && \
4457
/compose/.tox/${PY_ARG}/bin/pyinstaller --exclude-module pycrypto --exclude-module PyInstaller docker-compose.spec && \
4558
ls -la dist/ && \
@@ -48,7 +61,7 @@ RUN \
4861
docker-compose version
4962

5063
############## runtime stage ##############
51-
FROM lsiobase/ubuntu:arm64v8-bionic
64+
FROM lsiobase/alpine:arm64v8-3.12
5265

5366
ARG BUILD_DATE
5467
ARG VERSION

Dockerfile.armhf

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,39 @@
11
ARG DOCKER_VERSION=19.03.8
22

3-
FROM arm32v7/docker:${DOCKER_VERSION} AS docker-cli
3+
FROM docker:${DOCKER_VERSION} AS docker-cli
44

5-
FROM lsiobase/ubuntu:arm32v7-bionic AS build
5+
FROM lsiobase/alpine:arm32v7-3.12 AS build
66

77
ARG COMPOSE_VERSION
88

9-
RUN apt-get update && apt-get install --no-install-recommends -y \
9+
RUN \
10+
apk add --no-cache \
11+
bash \
12+
build-base \
13+
ca-certificates \
1014
curl \
1115
gcc \
1216
git \
1317
libc-dev \
1418
libffi-dev \
15-
libgcc-6-dev \
16-
libssl-dev \
19+
libgcc \
1720
make \
21+
musl-dev \
1822
openssl \
23+
openssl-dev \
1924
python3-dev \
20-
python3-pip \
21-
zlib1g-dev
25+
py3-pip \
26+
zlib-dev
2227

2328
COPY --from=docker-cli /usr/local/bin/docker /usr/local/bin/docker
2429

2530
RUN \
2631
mkdir -p /compose && \
2732
if [ -z ${COMPOSE_VERSION+x} ]; then \
2833
COMPOSE_VERSION=$(curl -sX GET "https://api.github.com/repos/docker/compose/releases/latest" \
29-
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
34+
| awk '/tag_name/{print $4;exit}' FS='[""]' | awk '$0="alpine-"$0'); \
3035
fi && \
36+
COMPOSE_VERSION=$(echo "$COMPOSE_VERSION" | sed 's|alpine-||') && \
3137
git clone https://github.com/docker/compose.git && \
3238
cd /compose && \
3339
git checkout "${COMPOSE_VERSION}" && \
@@ -40,6 +46,13 @@ RUN \
4046
chmod 777 dist && \
4147
/compose/.tox/${PY_ARG}/bin/pip3 install -q -r requirements-build.txt && \
4248
echo "$(script/build/write-git-sha)" > compose/GITSHA && \
49+
PYINSTVER=$(cat requirements-build.txt | grep pyinstaller | sed 's|pyinstaller==|v|') && \
50+
git clone --single-branch --branch develop https://github.com/pyinstaller/pyinstaller.git /tmp/pyinstaller && \
51+
cd /tmp/pyinstaller/bootloader && \
52+
git checkout $(PYINSTVER) && \
53+
/compose/.tox/${PY_ARG}/bin/python3 ./waf configure --no-lsb all && \
54+
/compose/.tox/${PY_ARG}/bin/pip3 install .. && \
55+
cd /compose && \
4356
export PATH="/compose/pyinstaller:${PATH}" && \
4457
/compose/.tox/${PY_ARG}/bin/pyinstaller --exclude-module pycrypto --exclude-module PyInstaller docker-compose.spec && \
4558
ls -la dist/ && \
@@ -48,7 +61,7 @@ RUN \
4861
docker-compose version
4962

5063
############## runtime stage ##############
51-
FROM lsiobase/ubuntu:arm32v7-bionic
64+
FROM lsiobase/alpine:arm32v7-3.12
5265

5366
ARG BUILD_DATE
5467
ARG VERSION

0 commit comments

Comments
 (0)