docker - 气流微风初始化失败
问题描述
我按照说明初始化微风环境:https ://github.com/apache/airflow/blob/main/CONTRIBUTORS_QUICK_START.rst#setting-up-breeze
似乎图像已构建但无法启动。我的环境有问题吗?
docker 20.10.9 的好版本。Python版本:3.8
后台:mysql
无需重建映像:重要文件均未更改
Use CI image.
Branch name: main
Docker image: ghcr.io/apache/airflow/main/ci/python3.8
Airflow source version: 2.3.0.dev0
Python version: 3.8
Backend: mysql 5.7
docker: Error response from daemon: OCI runtime create failed: container_linux.go:380: starting container process caused: process_linux.go:545: container init caused: rootfs_linux.go:76: mounting "/mnt/c/Users/binglilun/source/repos/doowhtron/airflow/scripts/in_container/entrypoint_ci.sh" to rootfs at "/entrypoint" caused: mount through procfd: not a directory: unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type.
解决方案
问题已解决。在我的 wsl 环境中运行微风的关键是:
- 升级到 wsl2(我的发行版是 ubuntu)
- 签出源到 ~/ 而不是 /mnt/c/
- 在wsl2中运行docker守护进程(不使用docker destop)
- 通过设置 /etc/resolv.conf(putting nameserver 8.8.8.8) 启用 wsl 的网络
- 在 docker_v build(_build_images.sh) 中添加“--network host”参数,否则无法连接互联网
- 安装纱线并将“--ignore-engines”添加到纱线安装(compile_assets.sh)
微风现在对我有用。
推荐阅读
- java - 如何在秒表后以正确的格式显示日期?
- arrays - 通过 TextBox 中的给定元素从数组中获取相关记录
- php - Laravel:一个表与另一个表没有关系
- node.js - 无法使用 npx create-react-app 安装反应应用程序。节点引擎“节点”与此模块不兼容
- sql - 使用 CTE,比较具有相同 ID 的行并将最旧的行更新为 0 SQL Server 2008
- amazon-web-services - TypeError: cognitoidentityserviceprovider.getUser(...).promise 不是函数
- ios - Nativescript OCR插件只识别iOS中抓拍图片的第二象限
- django - DRF 中 request.POST、request.data 和 request.GET 之间的确切区别是什么?
- ruby-on-rails - form_tag 中的验证
- javascript - 无法从承诺中捕获异常