prod & dev docker containers
This commit is contained in:
30
Dockerfile.dev
Normal file
30
Dockerfile.dev
Normal file
@@ -0,0 +1,30 @@
|
||||
# Development Dockerfile with full toolchain
|
||||
FROM rust:1.90
|
||||
|
||||
# Install development tools
|
||||
RUN apt-get update && apt-get install -y \
|
||||
pkg-config \
|
||||
libssl-dev \
|
||||
protobuf-compiler \
|
||||
redis-tools \
|
||||
netcat-openbsd \
|
||||
curl \
|
||||
vim \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Install cargo tools for development
|
||||
RUN cargo install cargo-watch cargo-edit
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy project files
|
||||
COPY . .
|
||||
|
||||
# Pre-build dependencies (optional, for faster startup)
|
||||
RUN cargo build
|
||||
|
||||
# Expose ports
|
||||
EXPOSE 6379 8080
|
||||
|
||||
# Development command with hot reload
|
||||
CMD ["cargo", "run", "--", "--dir", "/data", "--port", "6379", "--enable-rpc", "--rpc-port", "8080"]
|
||||
Reference in New Issue
Block a user