Skip to content

Commit

Permalink
Merge pull request #2698 from paulmaunders/fix-macos-go-tests
Browse files Browse the repository at this point in the history
Fix Go installation and benchmark tests for Apple Silicon
  • Loading branch information
paul-gauthier authored Dec 27, 2024
2 parents 1467a67 + b68f34e commit 98a0f1c
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ aider/_version.py
.venv/
.#*
.gitattributes
tmp.benchmarks/
16 changes: 12 additions & 4 deletions benchmark/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,18 @@ RUN apt-get update && apt-get install -y \
# Make python3.11 the default python3
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1

# Install Go
RUN curl -OL https://golang.org/dl/go1.21.5.linux-amd64.tar.gz && \
tar -C /usr/local -xzf go1.21.5.linux-amd64.tar.gz && \
rm go1.21.5.linux-amd64.tar.gz
# Install Go with architecture detection
RUN ARCH=$(uname -m) && \
if [ "$ARCH" = "x86_64" ]; then \
GOARCH="amd64"; \
elif [ "$ARCH" = "aarch64" ]; then \
GOARCH="arm64"; \
else \
false; \
fi && \
curl -L "https://golang.org/dl/go1.21.5.linux-$GOARCH.tar.gz" -o go.tar.gz && \
tar -C /usr/local -xzf go.tar.gz && \
rm go.tar.gz
ENV PATH="/usr/local/go/bin:${PATH}"

# Install Rust
Expand Down

0 comments on commit 98a0f1c

Please sign in to comment.