【问题标题】:Airflow on Kubernetes: couldn't parse image referenceKubernetes 上的气流:无法解析图像参考
【发布时间】:2021-08-06 17:34:30
【问题描述】:

在 GKE 中运行 Airflow。 当调度程序产生工作人员时,我面临下一个问题:

Failed to apply default image tag "my_registry_address_without_https:python:3.9.4-alpine": couldn't parse image reference "my_registry_address_without_https:python:3.9.4-alpine": invalid reference format

airflow.cfg 我有下一个配置:

# The repository of the Kubernetes Image for the Worker to Run
worker_container_repository = my_registry_address_without_https

# The tag of the Kubernetes Image for the Worker to Run
worker_container_tag = python:3.9.4-alpine

它应该正确解析,但无法理解,我错过了什么..

【问题讨论】:

  • 你好,试试把worker_container_tag = python:3.9.4-alpine改成worker_container_tag = python:3.9.5-alpineHere你可以找到,支持3.9.5-alpine这个标签。
  • 问题不在于版本,因为我不是从 Docker hub 中提取,而是从私有存储库中提取 invalid reference format 是错误(
  • 在参考文献中:my_registry_address_without_https:python:3.9.4-alpine 我不喜欢两个: 字符。看official docker doc。如果这个存储库是私有的,你可以更改他的名字以避免在他的标签中使用: 字符吗?或者您可以尝试将worker_container_tagworker_container_tag = {python:3.9.4-alpine} 分开?您也可以尝试使用"' 字符而不是{} 来分隔。
  • 这就是为什么我的问题在这里(我也不喜欢两个:),基于 Airflow 文档,这应该可以工作

标签: kubernetes airflow kubernetes-pod


【解决方案1】:

问题在于存储库的地址。它应该是注册表/图像:

# The repository of the Kubernetes Image for the Worker to Run
worker_container_repository = my_registry_address_without_https/python

# The tag of the Kubernetes Image for the Worker to Run
worker_container_tag = 3.9.4-alpine

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-07-25
    • 1970-01-01
    • 1970-01-01
    • 2021-09-05
    • 2020-09-20
    • 1970-01-01
    相关资源
    最近更新 更多