云容器实例 CCI-查询用户所有的Jobs:响应示例

时间:2023-12-01 17:06:33

响应示例

状态码: 200

OK

{
  "apiVersion" : "batch/v1",
  "items" : [ {
    "metadata" : {
      "creationTimestamp" : "2017-12-13T03:15:55Z",
      "labels" : {
        "name" : "job-test"
      },
      "name" : "jobs-12130306",
      "namespace" : "ns-12130306-s",
      "resourceVersion" : "419064",
      "selfLink" : "/apis/batch/v1/namespaces/ns-12130306-s/jobs/jobs-12130306",
      "uid" : "eed6b02b-dfb3-11e7-9c19-fa163e2d897b"
    },
    "spec" : {
      "completions" : 1,
      "parallelism" : 1,
      "selector" : {
        "matchLabels" : {
          "controller-uid" : "eed6b02b-dfb3-11e7-9c19-fa163e2d897b"
        }
      },
      "template" : {
        "metadata" : {
          "creationTimestamp" : null,
          "labels" : {
            "controller-uid" : "eed6b02b-dfb3-11e7-9c19-fa163e2d897b",
            "job-name" : "jobs-12130306",
            "name" : "job-test"
          },
          "name" : "jobs-12130306"
        },
        "spec" : {
          "containers" : [ {
            "image" : "172.16.5.235:20202/test/redis:latest",
            "imagePullPolicy" : "Always",
            "name" : "jobs-12130306",
            "resources" : { },
            "terminationMessagePath" : "/dev/termination-log",
            "terminationMessagePolicy" : "File"
          } ],
          "dnsPolicy" : "ClusterFirst",
          "restartPolicy" : "Never",
          "schedulerName" : "default-scheduler",
          "securityContext" : { }
        }
      }
    },
    "status" : {
      "active" : 1,
      "startTime" : "2017-12-13T03:15:55Z"
    }
  } ],
  "kind" : "JobList",
  "metadata" : {
    "resourceVersion" : "419065",
    "selfLink" : "/apis/batch/v1/jobs"
  }
}
support.huaweicloud.com/api-cci/listBatchV1JobForAllNamespaces.html