-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.base
executable file
·30 lines (30 loc) · 1.39 KB
/
Dockerfile.base
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
RUN sh -c 'set -ex \
&& cd /tmp/corpusopssteroids \
&& : \
&& chmod +x *sh \
&& if [ ! -e $COPS_HELPERS ];then mkdir -p "$COPS_HELPERS";fi \
&& export PATH=$(pwd):$PATH \
&& _cops_SYSTEM=$(./system_detect.sh) \
&& cat ${_cops_SYSTEM}_optional_packages*.txt optional_packages*.txt > optional_packages.txt \
&& cat ${_cops_SYSTEM}_packages*.txt > packages.txt \
&& : fix logrorate global conf \
&& if [ -e /var/log ];then touch /var/log/syslog /var/log/messages;fi \
&& ./${_cops_SYSTEM}_up.sh \
&& ./add_opt_pkgs.sh \
&& ./add_frep.sh \
&& ./add_remco.sh \
&& ./add_confd.sh \
&& ./add_dockerize.sh \
&& ./add_gosu.sh \
&& ./add_forego.sh \
&& ln -sfv ${COPS_HELPERS}/supervisord-go /bin/supervisord-go \
&& DEBUG=1 ./setup_locales.sh \
&& sed -i -re "/var\\/log\\/messages \\{\\}/d" /etc/logrotate.conf\
&& sed -i -re "s/ dateext/nodateext/g" /etc/logrotate.conf\
&& if ! (grep -q /var/log/messages /etc/logrotate.conf);then\
printf "\\n/var/log/messages {\\nmissingok\\n}\\n\\n" >>/etc/logrotate.conf;fi\
&& for i in bin/* system_detect.sh setup_locales.sh cops_pkgmgr_install.sh;do j=$(basename $i);cp -v $i /cops_helpers && ln -sfv /cops_helpers/$j /bin/$j;done\
&& ./${_cops_SYSTEM}_clean.sh \
'
COPY --from=ochinchina/supervisord:latest \
/usr/local/bin/supervisord ${COPS_HELPERS}/supervisord-go