Skip to content

Commit 513d5b7

Browse files
authored
Merge pull request #222 from Quantisan/fix/install-curl-explicitly
Fix: install curl explicitly in tools-deps images
2 parents 28a3175 + d7827ad commit 513d5b7

File tree

36 files changed

+100
-106
lines changed

36 files changed

+100
-106
lines changed

src/docker_clojure/core.clj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@
231231
(filter variant-filter (valid-variants))))
232232

233233
(defn run
234-
"Entrypoint for exec-fn. TODO: Make -main use this."
234+
"Entrypoint for exec-fn."
235235
[{:keys [cmd args parallelization]}]
236236
(logger/start)
237237
(let [variants (generate-variants args)]

src/docker_clojure/dockerfile/tools_deps.clj

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,14 @@
88
#(.setExecutable % true false)))
99

1010
(def distro-deps
11-
{:debian-slim {:build #{"wget" "curl"}
11+
{:debian-slim {:build #{"curl"}
1212
:runtime #{"rlwrap" "make" "git"}}
13-
:debian {:build #{"wget" "curl"}
14-
:runtime #{"rlwrap" "make" "git"}}
15-
:ubuntu {:build #{"wget"}
13+
:debian {:build #{"curl"}
1614
:runtime #{"rlwrap" "make" "git"}}
15+
:ubuntu {:build #{}
16+
;; install curl as a runtime dep b/c we need it at build time
17+
;; but upstream includes it so we don't want to uninstall it
18+
:runtime #{"rlwrap" "make" "git" "curl"}}
1719
:alpine {:build #{"curl"}
1820
:runtime #{"bash" "make" "git"}}})
1921

@@ -36,7 +38,7 @@
3638
"RUN \\"]
3739
(concat-commands install-dep-cmds)
3840
(concat-commands
39-
["wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh"
41+
["curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh"
4042
"sha256sum linux-install-$CLOJURE_VERSION.sh"
4143
(str "echo \"" (get-in installer-hashes ["tools-deps" build-tool-version]) " *linux-install-$CLOJURE_VERSION.sh\" | sha256sum -c -")
4244
"chmod +x linux-install-$CLOJURE_VERSION.sh"

target/debian-bookworm-11/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-17/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-21/latest/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,16 @@ WORKDIR /tmp
5050

5151
RUN \
5252
apt-get update && \
53-
apt-get install -y curl make git rlwrap wget && \
53+
apt-get install -y curl make git rlwrap && \
5454
rm -rf /var/lib/apt/lists/* && \
55-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
55+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
5656
sha256sum linux-install-$CLOJURE_VERSION.sh && \
5757
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
5858
chmod +x linux-install-$CLOJURE_VERSION.sh && \
5959
./linux-install-$CLOJURE_VERSION.sh && \
6060
rm linux-install-$CLOJURE_VERSION.sh && \
6161
clojure -e "(clojure-version)" && \
62-
apt-get purge -y --auto-remove curl wget
62+
apt-get purge -y --auto-remove curl
6363

6464
# Docker bug makes rlwrap crash w/o short sleep first
6565
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-21/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-22/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-8/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-slim-11/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

target/debian-bookworm-slim-17/tools-deps/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ WORKDIR /tmp
1010

1111
RUN \
1212
apt-get update && \
13-
apt-get install -y curl make git rlwrap wget && \
13+
apt-get install -y curl make git rlwrap && \
1414
rm -rf /var/lib/apt/lists/* && \
15-
wget https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
15+
curl -sLO https://download.clojure.org/install/linux-install-$CLOJURE_VERSION.sh && \
1616
sha256sum linux-install-$CLOJURE_VERSION.sh && \
1717
echo "7edee5b12197a2dbe6338e672b109b18164cde84bea1f049ceceed41fc4dd10a *linux-install-$CLOJURE_VERSION.sh" | sha256sum -c - && \
1818
chmod +x linux-install-$CLOJURE_VERSION.sh && \
1919
./linux-install-$CLOJURE_VERSION.sh && \
2020
rm linux-install-$CLOJURE_VERSION.sh && \
2121
clojure -e "(clojure-version)" && \
22-
apt-get purge -y --auto-remove curl wget
22+
apt-get purge -y --auto-remove curl
2323

2424
# Docker bug makes rlwrap crash w/o short sleep first
2525
# Bug: https://github.com/moby/moby/issues/28009

0 commit comments

Comments
 (0)