Skip to content

Commit b68f34e

Browse files
committed
feat: Fix Go installation for Apple Silicon and add tmp.benchmarks to gitignore
1 parent b51768b commit b68f34e

File tree

2 files changed

+13
-4
lines changed

2 files changed

+13
-4
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ aider/_version.py
1515
.venv/
1616
.#*
1717
.gitattributes
18+
tmp.benchmarks/

benchmark/Dockerfile

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,18 @@ RUN apt-get update && apt-get install -y \
1818
# Make python3.11 the default python3
1919
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1
2020

21-
# Install Go
22-
RUN curl -OL https://golang.org/dl/go1.21.5.linux-amd64.tar.gz && \
23-
tar -C /usr/local -xzf go1.21.5.linux-amd64.tar.gz && \
24-
rm go1.21.5.linux-amd64.tar.gz
21+
# Install Go with architecture detection
22+
RUN ARCH=$(uname -m) && \
23+
if [ "$ARCH" = "x86_64" ]; then \
24+
GOARCH="amd64"; \
25+
elif [ "$ARCH" = "aarch64" ]; then \
26+
GOARCH="arm64"; \
27+
else \
28+
false; \
29+
fi && \
30+
curl -L "https://golang.org/dl/go1.21.5.linux-$GOARCH.tar.gz" -o go.tar.gz && \
31+
tar -C /usr/local -xzf go.tar.gz && \
32+
rm go.tar.gz
2533
ENV PATH="/usr/local/go/bin:${PATH}"
2634

2735
# Install Rust

0 commit comments

Comments
 (0)