Skip to content

Commit

Permalink
Don't send source code when we're building base image.
Browse files Browse the repository at this point in the history
  • Loading branch information
NI committed Sep 8, 2019
1 parent 851d289 commit f2438e4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
# Build the build base environment
FROM debian:sid AS base
COPY . /tmp/.build/sshwifty
RUN set -ex && \
cd / && \
ls -l /tmp/.build/sshwifty && \
echo 'res=0; for i in $(seq 0 36); do $@; res=$?; [ $res -eq 0 ] && exit $res || sleep 10; done; exit $res' > /try.sh && chmod +x /try.sh && \
echo 'cpid=""; ret=0; i=0; for c in "$@"; do ( (((((eval $c; echo $? >&3) | sed "s/^/|-($i) /" >&4) 2>&1 | sed "s/^/|-($i)!/" >&2) 3>&1) | (read xs; exit $xs)) 4>&1) & ppid=$!; cpid="$cpid $ppid"; echo "+ Child $i (PID $ppid): $c ..."; i=$((i+1)); done; for c in $cpid; do wait $c; cret=$?; [ $cret -eq 0 ] && continue; echo "* Child PID $c has failed." >&2; ret=$cret; done; exit $ret' > /child.sh && chmod +x /child.sh && \
export PATH=$PATH:/ && \
Expand All @@ -14,7 +12,9 @@ RUN set -ex && \

# Build the base environment for application libraries
FROM base AS libbase
COPY . /tmp/.build/sshwifty
RUN set -ex && \
ls -l /tmp/.build/sshwifty && \
cd / && \
export PATH=$PATH:/ && \
([ -z "$HTTP_PROXY" ] || (git config --global http.proxy "$HTTP_PROXY" && npm config set proxy "$HTTP_PROXY")) && \
Expand Down

0 comments on commit f2438e4

Please sign in to comment.