-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3cdca71
commit e529aad
Showing
4 changed files
with
48 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,9 @@ | ||
# Use a base image that includes both Go and Node.js, such as the official Go image | ||
FROM golang:1.21.7-bullseye | ||
ARG AVALANCHEGO_VERSION | ||
FROM avaplatform/avalanche-cli:latest as avalanche-cli | ||
FROM avaplatform/avalanchego:$AVALANCHEGO_VERSION as avalanchego | ||
FROM mcr.microsoft.com/devcontainers/base | ||
|
||
ENV GOPATH=/go | ||
ENV PATH=$PATH:$GOPATH/bin | ||
ENV AVALANCHEGO_EXEC_PATH=$GOPATH/src/github.com/ava-labs/avalanchego/build/avalanchego | ||
ENV AVALANCHEGO_PLUGIN_PATH=$GOPATH/src/github.com/ava-labs/avalanchego/build/plugins | ||
|
||
# Install Node.js and npm using the official Node.js image | ||
RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && apt-get install -y nodejs | ||
|
||
# Clone the avalanchego repository | ||
RUN git clone -b v1.11.3 https://github.com/ava-labs/avalanchego.git $GOPATH/src/github.com/ava-labs/avalanchego | ||
|
||
# Set the working directory to the cloned repository | ||
WORKDIR $GOPATH/src/github.com/ava-labs/avalanchego | ||
|
||
# Build the avalanchego project using the sh script | ||
RUN ./scripts/build.sh | ||
COPY --from=avalanchego /avalanchego/build /go/src/github.com/ava-labs/avalanchego/build | ||
COPY --from=avalanche-cli /avalanche /usr/local/bin/avalanche | ||
|
||
RUN curl -sSfL https://raw.githubusercontent.com/ava-labs/avalanche-network-runner/main/scripts/install.sh | sh -s | ||
|
||
ENV PATH ~/bin:$PATH |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters