为什么这个 argo 工作流程 运行 没有?
Why doesn't this argo workflow run?
我正在尝试配置我的 Argo 工作流程。
我知道如何纠正错误,但如果他们不这样做,我该如何调试运行?
我在 运行 宁 Argo 3.0.10 Ubuntu 20.04
argo: v3.0.10
BuildDate: 2021-08-18T23:41:44Z
GitCommit: 0177e73b962136200517b7f301cd98cfbed02a31
GitTreeState: clean
GitTag: v3.0.10
GoVersion: go1.16.6
Compiler: gc
Platform: linux/amd64
我使用以下命令应用以下 YAML
argo 提交 test.yaml --watch:
{
"apiVersion": "argoproj.io/v1alpha1",
"kind": "Workflow",
"metadata": {
"annotations": {
"argo": "workflows"
},
"generateName": "hello-world-",
"labels": {
"workflows.argoproj.io/archive-strategy": "false"
},
"namespace": "argo"
},
"spec": {
"entrypoint": "entrypoint",
"parallelism": 3,
"podGC": {
"strategy": "OnWorkflowSuccess"
},
"securityContext": {
"fsGroup": 2000,
"runAsGroup": 3000,
"runAsNonRoot": true,
"runAsUser": 1000
},
"serviceAccountName": "argouser",
"templates": [
{
"container": {
"args": [
"hello world"
],
"command": [
"cowsay"
],
"image": "docker/whalesay:latest",
"resources": {
"limits": {
"cpu": "100m",
"memory": "32Mi"
}
}
},
"name": "entrypoint"
}
],
"ttlStrategy": {
"secondsAfterSuccess": 5
}
}
}
据我所知,pods 从未创建过,也没有它们的记录,但是,工作流存在。这是工作流的 kubectl describe 的输出:
apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
annotations:
argo: workflows
creationTimestamp: "2021-09-07T20:48:37Z"
generateName: hello-world-
generation: 1
labels:
workflows.argoproj.io/archive-strategy: "false"
name: hello-world-p6h4k
namespace: argo
resourceVersion: "14801149"
uid: ee28ae8d-970e-47c6-83ee-fcdc6db44c39
spec:
arguments: {}
entrypoint: entrypoint
parallelism: 3
podGC:
strategy: OnWorkflowSuccess
securityContext:
fsGroup: 2000
runAsGroup: 3000
runAsNonRoot: true
runAsUser: 1000
serviceAccountName: argouser
templates:
- container:
args:
- hello world
command:
- cowsay
image: docker/whalesay:latest
name: ""
resources:
limits:
cpu: 100m
memory: 32Mi
inputs: {}
metadata: {}
name: entrypoint
outputs: {}
ttlStrategy:
secondsAfterSuccess: 5
status:
finishedAt: null
startedAt: null
“错误”消息是:
Name: hello-world-p6h4k
Namespace: argo
ServiceAccount: argouser
Status: Pending
Created: Tue Sep 07 20:48:37 +0000 (now)
Progress:
FATA[2021-09-07T20:48:37.186Z] workflows.argoproj.io "hello-world-p6h4k" not found
感谢@Michael Crenshaw 的提示!
我查看了 workflow-controller-logs,工作流 运行 成功,但没有输出任何 argo 日志,工作流仍被列为待处理。我仍在寻找正确的配置,所以我不确定这些消息是如何不一致的。如果我找到答案,我会post在这里。
我认为出现“错误”消息的原因是 cli 命令省略了命名空间,试试这个:
argo submit test.yaml --watch -n argo
然后您可以检查您的 Workflow CRD 对象,它包含错误消息。可能您需要在 test.yaml
中设置正确的 serviceAccountName
和 namespace
我正在尝试配置我的 Argo 工作流程。
我知道如何纠正错误,但如果他们不这样做,我该如何调试运行?
我在 运行 宁 Argo 3.0.10 Ubuntu 20.04
argo: v3.0.10
BuildDate: 2021-08-18T23:41:44Z
GitCommit: 0177e73b962136200517b7f301cd98cfbed02a31
GitTreeState: clean
GitTag: v3.0.10
GoVersion: go1.16.6
Compiler: gc
Platform: linux/amd64
我使用以下命令应用以下 YAML
argo 提交 test.yaml --watch:
{
"apiVersion": "argoproj.io/v1alpha1",
"kind": "Workflow",
"metadata": {
"annotations": {
"argo": "workflows"
},
"generateName": "hello-world-",
"labels": {
"workflows.argoproj.io/archive-strategy": "false"
},
"namespace": "argo"
},
"spec": {
"entrypoint": "entrypoint",
"parallelism": 3,
"podGC": {
"strategy": "OnWorkflowSuccess"
},
"securityContext": {
"fsGroup": 2000,
"runAsGroup": 3000,
"runAsNonRoot": true,
"runAsUser": 1000
},
"serviceAccountName": "argouser",
"templates": [
{
"container": {
"args": [
"hello world"
],
"command": [
"cowsay"
],
"image": "docker/whalesay:latest",
"resources": {
"limits": {
"cpu": "100m",
"memory": "32Mi"
}
}
},
"name": "entrypoint"
}
],
"ttlStrategy": {
"secondsAfterSuccess": 5
}
}
}
据我所知,pods 从未创建过,也没有它们的记录,但是,工作流存在。这是工作流的 kubectl describe 的输出:
apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
annotations:
argo: workflows
creationTimestamp: "2021-09-07T20:48:37Z"
generateName: hello-world-
generation: 1
labels:
workflows.argoproj.io/archive-strategy: "false"
name: hello-world-p6h4k
namespace: argo
resourceVersion: "14801149"
uid: ee28ae8d-970e-47c6-83ee-fcdc6db44c39
spec:
arguments: {}
entrypoint: entrypoint
parallelism: 3
podGC:
strategy: OnWorkflowSuccess
securityContext:
fsGroup: 2000
runAsGroup: 3000
runAsNonRoot: true
runAsUser: 1000
serviceAccountName: argouser
templates:
- container:
args:
- hello world
command:
- cowsay
image: docker/whalesay:latest
name: ""
resources:
limits:
cpu: 100m
memory: 32Mi
inputs: {}
metadata: {}
name: entrypoint
outputs: {}
ttlStrategy:
secondsAfterSuccess: 5
status:
finishedAt: null
startedAt: null
“错误”消息是:
Name: hello-world-p6h4k
Namespace: argo
ServiceAccount: argouser
Status: Pending
Created: Tue Sep 07 20:48:37 +0000 (now)
Progress:
FATA[2021-09-07T20:48:37.186Z] workflows.argoproj.io "hello-world-p6h4k" not found
感谢@Michael Crenshaw 的提示!
我查看了 workflow-controller-logs,工作流 运行 成功,但没有输出任何 argo 日志,工作流仍被列为待处理。我仍在寻找正确的配置,所以我不确定这些消息是如何不一致的。如果我找到答案,我会post在这里。
我认为出现“错误”消息的原因是 cli 命令省略了命名空间,试试这个:
argo submit test.yaml --watch -n argo
然后您可以检查您的 Workflow CRD 对象,它包含错误消息。可能您需要在 test.yaml
serviceAccountName
和 namespace