Skip to content

Commit

Permalink
Fix: upgrade definitions in charts (#118)
Browse files Browse the repository at this point in the history
Signed-off-by: FogDong <[email protected]>

Signed-off-by: FogDong <[email protected]>
  • Loading branch information
FogDong authored Jan 12, 2023
1 parent 03ed8af commit 95c2164
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 7 deletions.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,6 @@ vela addon enable vela-workflow

Please checkout: [Install Vela CLI](https://kubevela.io/docs/installation/kubernetes#install-vela-cli)

> Note that if you installed Workflow using KubeVela Addon, then the definitions in the addon will be installed automatically.
## Features

- [Operate WorkflowRun](https://kubevela.io/docs/next/end-user/pipeline/workflowrun#operate-workflowrun)
Expand Down
2 changes: 1 addition & 1 deletion charts/vela-workflow/templates/definitions/apply-app.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ spec:
}
}
wait: op.#ConditionalWait & {
continue: app.apply.value.status.status == "running"
continue: app.apply.value.status.status == "running" && app.apply.value.status.observedGeneration == app.apply.value.metadata.generation
}
parameter: close({
data?: {...}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ spec:
}
}
wait: op.#ConditionalWait & {
continue: output.value.status.readyReplicas == 1
continue: output.value.status != _|_ && output.value.status.updatedReplicas == output.value.status.availableReplicas && output.value.status.observedGeneration == output.value.metadata.generation
}
parameter: {
image: string
Expand Down
25 changes: 22 additions & 3 deletions charts/vela-workflow/templates/definitions/vela-cli.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,24 @@ spec:
mountsArray: [
if parameter.storage != _|_ && parameter.storage.secret != _|_ for v in parameter.storage.secret {
{
name: "secret-" + v.name
mountPath: v.mountPath
if v.subPath != _|_ {
subPath: v.subPath
}
name: v.name
}
},
if parameter.storage != _|_ && parameter.storage.hostPath != _|_ for v in parameter.storage.hostPath {
{
name: "hostpath-" + v.name
mountPath: v.mountPath
}
},
]
volumesList: [
if parameter.storage != _|_ && parameter.storage.secret != _|_ for v in parameter.storage.secret {
{
name: v.name
name: "secret-" + v.name
secret: {
defaultMode: v.defaultMode
secretName: v.secretName
Expand All @@ -39,6 +45,12 @@ spec:
}
}
}
if parameter.storage != _|_ && parameter.storage.hostPath != _|_ for v in parameter.storage.hostPath {
{
name: "hostpath-" + v.name
path: v.path
}
}
},
]
deDupVolumesArray: [
Expand Down Expand Up @@ -69,7 +81,7 @@ spec:
spec: {
backoffLimit: 3
template: {
labels: "workflow.oam.dev/step-name": "\(context.name)-\(context.stepName)"
metadata: labels: "workflow.oam.dev/step-name": "\(context.name)-\(context.stepName)"
spec: {
containers: [
{
Expand Down Expand Up @@ -125,6 +137,13 @@ spec:
mode: *511 | int
}]
}]
// +usage=Declare host path type storage
hostPath?: [...{
name: string
path: string
mountPath: string
type: *"Directory" | "DirectoryOrCreate" | "FileOrCreate" | "File" | "Socket" | "CharDevice" | "BlockDevice"
}]
}
}

0 comments on commit 95c2164

Please sign in to comment.