Spaces:
Build error

File size: 1,063 Bytes
f832ee5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
FROM rust:1.77-bookworm AS builder

# Install build dependencies
RUN apt-get update && apt-get install -y pkg-config libssl-dev cmake build-essential clang llvm

WORKDIR /usr/src/qanto
# Copy the entire workspace
COPY . .

# Build the qanto and qantowallet bins in release mode
RUN cargo build --release --bin qanto
RUN cargo build --release --bin qantowallet

FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y libssl-dev ca-certificates curl && rm -rf /var/lib/apt/lists/*

WORKDIR /app
COPY --from=builder /usr/src/qanto/target/release/qanto /app/
COPY --from=builder /usr/src/qanto/target/release/qantowallet /app/
# Copy default config template if we have one
COPY --from=builder /usr/src/qanto/Protocol_Core/qanto-node/config.toml /app/config.toml || echo "No config.toml found, will use args" > /dev/null

ENV WALLET_PASSWORD=""
ENV RUST_LOG="info"

EXPOSE 8080
EXPOSE 7860

# Generate a default wallet on first run if none exists, then start node
CMD ./qanto generate-wallet --output wallet.key && ./qanto start --wallet wallet.key --mine