This repository has been archived by the owner on Feb 3, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 17
/
Dockerfile
89 lines (79 loc) · 1.94 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
FROM lsiobase/alpine:3.11 as buildstage
ARG COMPOSE_VERSION=1.24.1
ARG PYINSTALLER_VERSION=v3.6
RUN \
echo "**** install build deps ****" && \
apk add --no-cache \
curl \
g++ \
gcc \
git \
libc-dev \
libffi-dev \
make \
musl-dev \
openssl-dev \
python3 \
python3-dev \
zlib-dev
RUN \
echo "**** build pyinstaller ****" && \
git clone --depth 1 \
--single-branch \
--branch ${PYINSTALLER_VERSION} \
https://github.com/pyinstaller/pyinstaller.git \
/tmp/pyinstaller && \
cd /tmp/pyinstaller/bootloader && \
CFLAGS="-Wno-stringop-overflow -Wno-error=stringop-truncation" python3 \
./waf configure --no-lsb all && \
pip3 install ..
RUN \
echo "**** build compose ****" && \
cd /tmp && \
git clone https://github.com/docker/compose.git && \
cd compose && \
git checkout ${COMPOSE_VERSION} && \
pip3 install \
-r requirements.txt && \
./script/build/write-git-sha > compose/GITSHA && \
pyinstaller docker-compose.spec && \
mv dist/docker-compose /
# runtime stage
FROM lsiobase/cloud9:alpine
MAINTAINER Ryan Kuba <[email protected]>
# Set Label info
ARG BUILD_DATE
LABEL build_version="Build-date:- ${BUILD_DATE}"
RUN \
echo "**** install build packages ****" && \
apk add --no-cache --virtual=build-dependencies \
curl \
nodejs-npm && \
echo "**** install runtime packages ****" && \
apk add --no-cache \
docker-cli \
expect \
git \
libcap \
nodejs \
sudo \
tcl && \
echo "**** install Taisun ****" && \
git clone https://github.com/Taisun-Docker/taisun.git /code && \
echo "**** install node modules ****" && \
npm install --prefix /code && \
npm install -g nodemon && \
mv /usr/bin/git /usr/bin/gitbin && \
echo "**** cleanup ****" && \
addgroup -g 100 docker && \
apk del --purge \
build-dependencies && \
rm -rf \
/tmp/*
# copy local files
COPY root/ /
COPY ./git /usr/bin/git
COPY --from=buildstage /docker-compose /usr/local/bin/
#App runs on port 3000 development interface on port 8000
EXPOSE 3000
EXPOSE 8000