runner: switch to client API

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
This commit is contained in:
Andrea Luzzardi 2022-03-07 16:02:42 -08:00
parent 0786410bbd
commit b33b75a570
3 changed files with 4 additions and 7 deletions

View File

@ -17,7 +17,7 @@ import (
var (
ActionSelector = cue.Str("actions")
OutputSelector = cue.Str("outputs")
ClientSelector = cue.Str("client")
)
type Plan struct {

View File

@ -89,9 +89,9 @@ func (r *Runner) initTasks() {
}
}
// If an `output` task is targeting an allowed task, allow the output task as well
// If a `client` task is targeting an allowed task, allow the output task as well
for _, t := range flow.Tasks() {
if t.Path().Selectors()[0] != OutputSelector {
if t.Path().Selectors()[0] != ClientSelector {
continue
}
for _, dep := range t.Dependencies() {

View File

@ -8,10 +8,7 @@ import (
)
dagger.#Plan & {
outputs: files: test: {
dest: "./test_do"
contents: actions.test.one.export.files["/output.txt"]
}
client: filesystem: "./test_do": write: contents: actions.test.one.export.files["/output.txt"]
actions: {
image: alpine.#Build & {