qqbot-deno/Dockerfile

22 lines
494 B
Docker

# 使用官方 Node.js 20.18.0 版本的 slim 镜像作为基础镜像
FROM node:20.18.0
# 安装 Deno
RUN curl -fsSL https://x.deno.js.cn/install.sh | sh
# 将 Deno 的可执行文件路径添加到 PATH 环境变量中
ENV DENO_INSTALL="/root/.deno"
ENV PATH="$DENO_INSTALL/bin:$PATH"
# 设置工作目录
WORKDIR /app
# 将本地文件复制到容器中
COPY . .
RUN npm config set registry https://registry.npmmirror.com
RUN npm install
# 运行您的应用
CMD ["npm", "run", "dev"]