-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
42 lines (33 loc) · 1.11 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Use a base image with the required GLIBC version
FROM ubuntu:20.04
# Install dependencies including git and python
RUN apt-get update && apt-get install -y \
curl \
build-essential \
wget \
ca-certificates \
libssl-dev \
git \
python3 \
python3-distutils \
&& curl -fsSL https://deb.nodesource.com/setup_16.x | bash - \
&& apt-get install -y nodejs \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Install Foundry and Anvil
RUN curl -L https://foundry.paradigm.xyz | bash \
&& ~/.foundry/bin/foundryup
# Install Avalanche CLI
RUN curl -sSfL https://raw.githubusercontent.com/ava-labs/avalanche-cli/main/scripts/install.sh | sh -s
# Set up environment variables for Foundry and Avalanche CLI
ENV PATH="/root/.foundry/bin:/root/bin:${PATH}"
# Create and change to the app directory inside the container
WORKDIR /usr/src/app
# Copy package.json and package-lock.json
COPY package*.json ./
# Install Node.js dependencies
RUN npm install
# Copy the rest of the application code
COPY . .
# The command to keep the container running and allow for command execution
CMD ["bash"]