ADO:验证数据时出错:服务器找不到请求的 [英] ADO: error validating data: the server could not find the requested

查看:0
本文介绍了ADO:验证数据时出错:服务器找不到请求的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我面对的是similar issue。";Deployment.yml";已成功应用,但";Services.yml";提供了

验证数据时出错:服务器找不到请求的 资源

Deployment.yml

--- 
apiVersion: apps/v1
kind: Deployment
metadata: 
  name: #{component}#
spec: 
  replicas: #{replica}#
  selector: 
    matchLabels: 
      app: #{component}#
  template: 
    metadata: 
      labels: 
        app: #{component}#
    spec: 
      containers: 
        - 
          env: 
            - 
              name: AUTHOR
              value: #{author}#
          image: #{acr}#/#{component}#:#{stage}#-#{Build.BuildId}#
          imagePullPolicy: Always
          name: #{component}#
          ports: 
            - 
              containerPort: 8000
          resources: 
            limits: 
              cpu: "1"
              memory: 512Mi
            requests: 
              cpu: "0.25"
              memory: 256Mi
      imagePullSecrets: 
        - 
          name: "acrakssecret"

Services.yml

--- 
apiVersion: v1
kind: Service
metadata: 
  name: #{component}#
spec: 
  ports: 
    - 
      name: #{component}#
      port: 443
      protocol: TCP
      targetPort: 8000
  selector: 
      app: #{component}#
  type: LoadBalancer

Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.0", GitCommit:"cb303e613a121a29364f75cc67d3d580833a7479", GitTreeState:"clean", BuildDate:"2021-04-08T16:31:21Z", GoVersion:"go1.16.1", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"20", GitVersion:"v1.20.5", GitCommit:"54684493f8139456e5d2f963b23cb5003c4d8055", GitTreeState:"clean", BuildDate:"2021-03-22T23:02:59Z", GoVersion:"go1.15.8", Compiler:"gc", Platform:"linux/amd64"}

通过kubectl控制台部署时,成功应用了";Services.yml";。有什么帮助吗?

推荐答案

作为对我的支持票证的回应,微软提供了this article,只需勾选kubectl任务的高级部分中的‘检查最新版本’即可解决该问题。

希望这能帮助他人:)

这篇关于ADO:验证数据时出错:服务器找不到请求的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆