0

这是我的 cloudbuild.json

{
    "steps": [
        {
            "name": "gcr.io/cloud-builders/docker",
            "args": [
                "build",
                "-t",
                "trainer_image",
                "."
            ],
            "dir": "./trainer_image/"
        },
        {
            "name": "gcr.io/cloud-builders/docker",
            "args": [
                "build",
                "-t",
                "base_image",
                "."
            ],
            "dir": "./base_image/"
        },
        {
            "name": "gcr.io/dmgcp-pkg-internal-poc-oct-04/kfp-cli",
            "args": [
                "dsl-compile --py covertype_training_pipeline.py --output covertype_training_pipeline.yaml"
            ],
            "env": [
                "BASE_IMAGE=gcr.io/dmgcp-pkg-internal-poc-oct-04/base_image:test",
                "TRAINER_IMAGE=gcr.io/dmgcp-pkg-internal-poc-oct-04/trainer_image:test",
                "RUNTIME_VERSION=1.15",
                "PYTHON_VERSION=3.7",
                "COMPONENT_URL_SEARCH_PREFIX=https://raw.githubusercontent.com/kubeflow/pipelines/0.2.5/components/gcp/",
                "USE_KFP_SA=False"
            ],
            "dir": "./pipeline/"
        },
        {
            "name": "gcr.io/dmgcp-pkg-internal-poc-oct-04/kfp-cli",
            "args": [
                "-c",
                "kfp --endpoint 66df1d31e46e6510-dot-us-central2.pipelines.googleusercontent.com/ pipeline upload -p credit_fraud_training_test covertype_training_pipeline.yaml"
            ],
            "dir": "./pipeline/"
        }
    ],
    "images": [
        "gcr.io/dmgcp-pkg-internal-poc-oct-04/trainer_image:test",
        "gcr.io/dmgcp-pkg-internal-poc-oct-04/base_image:test"
    ]
}

问题出在第 2 步:这是我得到的错误 “第 2 步:gcr.io/dmgcp-pkg-internal-poc-oct-04/kfp-cli:latest 第 2 步:/bin/bash:dsl-编译 --py covertype_training_pipeline.py --output covertype_training_pipeline.yaml:没有这样的文件或目录完成步骤#2“ 我正在运行这个命令来运行管道“!gcloud builds submit.--config cloudbuild.json”

她是我的文件夹结构 在此处输入图像描述 在此处输入图像描述

4

1 回答 1

0

你的 Dockerfile 中有什么?

“dsl编译--pycovertype_training_pipeline.py--输出covertype_training_pipeline.yaml”

您确定这可以作为单个字符串工作吗?

“目录”:“./管道/”

你确定这个相对路径是正确的吗?

PS 您可以创建自编译管道,将 dsl-compile 排除在外。

于 2020-09-22T06:15:37.860 回答