添加多个开发环境的 Docker 配置,包括 Debian、Maven、LaTeX 和 Rust,移除旧的 Rust 配置

This commit is contained in:
2025-05-03 15:29:58 +08:00
parent 3f454b9805
commit aca5f52bc2
11 changed files with 101 additions and 19 deletions

21
rust/Containerfile Normal file
View File

@@ -0,0 +1,21 @@
# 使用官方Rust镜像
FROM rust:latest
# 安装必要的系统依赖和工具
RUN apt-get update && \
apt-get install -y \
build-essential \
libssl-dev \
pkg-config \
git \
vim \
curl && \
apt-get clean &&\
rm -rf /var/lib/apt/lists/*
# 配置工作目录
#WORKDIR /app
WORKDIR /workspace
# 设置默认启动命令
CMD ["bash"]

13
rust/compose.yaml Normal file
View File

@@ -0,0 +1,13 @@
services:
rust-dev:
image: rust-dev:v1
build:
context: .
dockerfile: Containerfile
hostname: rust-devcontainer
container_name: rust-dev
volumes:
- /workspace/projects:/workspace
working_dir: /workspace
tty: true
stdin_open: true