Skip to content

Commit

Permalink
temp
Browse files Browse the repository at this point in the history
  • Loading branch information
juztamau5 committed Mar 12, 2024
1 parent 737d3f7 commit e0f214c
Showing 1 changed file with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,54 @@ WORKDIR /opt/cartesi/dapp
COPY src/backend .
RUN make

#
# builder2
#

FROM --platform=linux/riscv64 riscv64/ubuntu:22.04 as builder2

# Install OpanAI dependencies
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
build-essential \
cmake \
git \
libgtest-dev \
liblua5.1-dev \
lua5.1 \
python3 \
python3-dev \
python3-pip
rm -rf /var/lib/apt/lists/*
EOF
RUN python3 -m pip install --upgrade pip setuptools setuptools_scm

# Build OpenAI modules
WORKDIR /opt/cartesi/dapp/openai
COPY openai .
RUN cmake . -DBUILD_LUAJIT=OFF
RUN make -j8

# Install learning dependencies
RUN <<EOF
set -e
apt-get update
apt-get install -y --no-install-recommends \
autoconf \
automake \
ninja-build
rm -rf /var/lib/apt/lists/*
EOF
RUN python3 -m pip install --upgrade \
gymnasium \
numpy

# Copy learning modules
WORKDIR /opt/cartesi/dapp/src/learning
COPY src/learning .

#
# host
#
Expand All @@ -60,5 +108,6 @@ ENV PATH="/opt/cartesi/bin:${PATH}"

WORKDIR /opt/cartesi/dapp
COPY --from=builder /opt/cartesi/dapp/dapp .
COPY --from=builder2 /opt/cartesi/dapp/dapp temp

ENTRYPOINT ["/opt/cartesi/dapp/dapp"]

0 comments on commit e0f214c

Please sign in to comment.