Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions build/clean_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,15 @@ fi
mkdir -p src pkg bin "$(dirname "$tc_dir")"
)
rsync -a --exclude=/dist --exclude=/.m2 "${tc_volume}/" "$tc_dir";
if ! [ -d ${tc_dir}/.git ]; then
if [ -d "${tc_volume}/.git" ] && [ ! -d ${tc_dir}/.git ]; then
rsync -a "${tc_volume}/.git" $tc_dir; # Docker for Windows compatibility
fi

cd "$tc_dir"
# In case the mirrored repo already exists, remove gitignored files
git clean -fdX
if [ -d "${tc_volume}/.git" ]; then
# In case the mirrored repo already exists, remove gitignored files
git clean -fdX
fi

rm -rf "dist"
mkdir -p "${tc_volume}/dist"
Expand Down
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-docs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ RUN python3 -m pip install --upgrade setuptools && \
python3 -m pip install -r /docs.requirements.txt
###

ADD build/clean_build.sh /
CMD /clean_build.sh docs
CMD /trafficcontrol/build/clean_build.sh docs

# vi:syntax=Dockerfile
4 changes: 1 addition & 3 deletions infrastructure/docker/build/Dockerfile-grove
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,8 @@ RUN go_version=$(cat /GO_VERSION) && \

###

ADD build/clean_build.sh /

ENV GOPATH=/go
RUN mkdir -p /go/src/github.com/apache && ln -s /tmp/trafficcontrol /go/src/github.com/apache/trafficcontrol
CMD /clean_build.sh grove
CMD /trafficcontrol/build/clean_build.sh grove

# vi:syntax=Dockerfile
4 changes: 1 addition & 3 deletions infrastructure/docker/build/Dockerfile-grovetccfg
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,8 @@ RUN go_version=$(cat /GO_VERSION) && \

###

ADD build/clean_build.sh /

ENV GOPATH=/go
RUN mkdir -p /go/src/github.com/apache && ln -s /tmp/trafficcontrol /go/src/github.com/apache/trafficcontrol
CMD /clean_build.sh grove/grovetccfg
CMD /trafficcontrol/build/clean_build.sh grove/grovetccfg

# vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-source
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ RUN yum -y install \
yum -y clean all

WORKDIR /trafficcontrol
ADD build/clean_build.sh /
CMD /clean_build.sh tarball
CMD build/clean_build.sh tarball

# vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-traffic_monitor
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ RUN go_version=$(cat /GO_VERSION) && \

###

ADD build/clean_build.sh /
CMD /clean_build.sh traffic_monitor
CMD /trafficcontrol/build/clean_build.sh traffic_monitor

# vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-traffic_ops
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ RUN go_version=$(cat /GO_VERSION) && \

###

ADD build/clean_build.sh /
CMD /clean_build.sh traffic_ops
CMD /trafficcontrol/build/clean_build.sh traffic_ops

# vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-traffic_ops_ort
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ RUN go_version=$(cat /GO_VERSION) && \
ln -s /usr/local/go/bin/go /usr/bin/go && \
rm go.tar.gz

ADD build/clean_build.sh /
CMD /clean_build.sh traffic_ops_ort
CMD /trafficcontrol/build/clean_build.sh traffic_ops_ort

#vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-traffic_portal
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ RUN echo '{ "allow_root": true }' > /root/.bowerrc

###

ADD build/clean_build.sh /
CMD /clean_build.sh traffic_portal
CMD /trafficcontrol/build/clean_build.sh traffic_portal

# vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-traffic_router
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ RUN curl -L https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3

###

ADD build/clean_build.sh /
CMD /clean_build.sh traffic_router
CMD /trafficcontrol/build/clean_build.sh traffic_router

# vi:syntax=Dockerfile
3 changes: 1 addition & 2 deletions infrastructure/docker/build/Dockerfile-traffic_stats
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ RUN go_version=$(cat /GO_VERSION) && \

###

ADD build/clean_build.sh /
CMD /clean_build.sh traffic_stats
CMD /trafficcontrol/build/clean_build.sh traffic_stats

# vi:syntax=Dockerfile