Merge pull request #59 from blocklayerhq/cue-lint-all

lint all cue files
This commit is contained in:
Andrea Luzzardi 2021-01-20 21:46:31 -08:00 committed by GitHub
commit 05b45aa636
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
46 changed files with 574 additions and 660 deletions

View File

@ -19,7 +19,7 @@ test:
.PHONY: cuefmt .PHONY: cuefmt
cuefmt: cuefmt:
@(cd ./dagger && cue fmt -s ./... && cue trim -s ./...) @(cue fmt -s ./... && cue trim -s ./...)
.PHONY: lint .PHONY: lint
lint: generate cuefmt lint: generate cuefmt

View File

@ -1,5 +1,3 @@
package testing package testing
#dagger: { #dagger: compute: true
compute: true
}

View File

@ -1,5 +1,3 @@
package testing package testing
#dagger: { #dagger: compute: 123
compute: 123
}

View File

@ -1,5 +1,3 @@
package testing package testing
#dagger: { #dagger: compute: "whatever"
compute: "whatever"
}

View File

@ -1,7 +1,3 @@
package testing package testing
#dagger: { #dagger: compute: whatever: "wrong"
compute: {
whatever: "wrong"
}
}

View File

@ -1,15 +1,13 @@
package testing package testing
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["true"]
args: ["true"] dir: "/"
dir: "/" },
} ]
]
}

View File

@ -7,14 +7,14 @@ bar: string
#dagger: { #dagger: {
compute: [ compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
dir: "/" dir: "/"
args: ["sh", "-c", "echo \(foo.bar)"] args: ["sh", "-c", "echo \(foo.bar)"]
} },
] ]
foo: bar: bar foo: bar: bar
} }

View File

@ -3,47 +3,43 @@ package testing
test1: { test1: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox"
ref: "busybox" },
}, {
{ do: "copy"
do: "copy" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] src: "/etc/issue"
src: "/etc/issue" dest: "/"
dest: "/" },
}, {
{ do: "export"
do: "export" source: "/issue"
source: "/issue" format: "string"
format: "string" },
}, ]
]
}
} }
test2: { test2: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox"
ref: "busybox" },
}, {
{ do: "copy"
do: "copy" from: [{do: "fetch-container", ref: "busybox"}]
from: [{do: "fetch-container", ref: "busybox"}] src: "/etc/issue"
src: "/etc/issue" dest: "/"
dest: "/" },
}, {
{ do: "export"
do: "export" source: "/issue"
source: "/issue" format: "string"
format: "string" },
}, ]
]
}
} }

View File

@ -1,69 +1,65 @@
package testing package testing
component: #dagger: compute: [{ component: #dagger: compute: [{
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, { }, {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
printf lol > /id printf lol > /id
"""] """]
dir: "/" dir: "/"
}] }]
test1: { test1: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox"
ref: "busybox" },
}, {
{ do: "copy"
do: "copy" from: component
from: component src: "/id"
src: "/id" dest: "/"
dest: "/" },
}, {
{ do: "export"
do: "export" source: "/id"
source: "/id" format: "string"
format: "string" },
}, ]
]
}
} }
test2: { test2: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox"
ref: "busybox" },
}, {
{ do: "copy"
do: "copy" from: #dagger: compute: [{
from: #dagger: compute: [{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" }, {
}, { do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
printf lol > /id printf lol > /id
"""] """]
dir: "/" dir: "/"
}] }]
src: "/id" src: "/id"
dest: "/" dest: "/"
}, },
{ {
do: "export" do: "export"
source: "/id" source: "/id"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -3,23 +3,21 @@ package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox"
ref: "busybox" },
}, {
{ do: "copy"
do: "copy" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] src: "/etc/issue"
src: "/etc/issue" dest: "/"
dest: "/" },
}, {
{ do: "export"
do: "export" source: "/issue"
source: "/issue" format: "string"
format: "string" },
}, ]
]
}
} }

View File

@ -2,14 +2,14 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["echo", "always output"] args: ["echo", "always output"]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
always: true always: true
}, },
] ]

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {

View File

@ -2,15 +2,15 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo "pwd is: $(pwd)" echo "pwd is: $(pwd)"
[ "$(pwd)" == "/etc" ] || exit 1 [ "$(pwd)" == "/etc" ] || exit 1
"""] """]
dir: "/etc" dir: "/etc"
}, },
] ]

View File

@ -2,15 +2,15 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", #""" args: ["sh", "-c", #"""
echo "$foo" echo "$foo"
"""#] """#]
env: foo: {lala: "lala"} env: foo: lala: "lala"
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },

View File

@ -4,15 +4,15 @@ bar: string
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo "foo: $foo" echo "foo: $foo"
[ "$foo" == "overlay environment" ] || exit 1 [ "$foo" == "overlay environment" ] || exit 1
"""] """]
env: foo: bar env: foo: bar
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"

View File

@ -2,14 +2,14 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
[ "$foo" == "output environment" ] || exit 1 [ "$foo" == "output environment" ] || exit 1
"""] """]
env: foo: "output environment" env: foo: "output environment"
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
@ -10,4 +10,4 @@ package testing
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },
} ]

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {

View File

@ -3,27 +3,24 @@ package testing
test: { test: {
bool bool
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
printf "true" > /tmp/out printf "true" > /tmp/out
""" """,
] ]
dir: "/" dir: "/"
}, },
{ {
do: "export" do: "export"
// Source path in the container // Source path in the container
source: "/tmp/out" source: "/tmp/out"
format: "bool" format: "bool"
}, },
] ]
}
} }

View File

@ -5,19 +5,19 @@ test1: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol1 > /tmp/out echo lol1 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -29,19 +29,19 @@ test2: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol2 > /tmp/out echo lol2 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -53,19 +53,19 @@ test3: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol3 > /tmp/out echo lol3 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -77,19 +77,19 @@ test4: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol4 > /tmp/out echo lol4 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -101,19 +101,19 @@ test5: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol5 > /tmp/out echo lol5 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -125,19 +125,19 @@ test6: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol6 > /tmp/out echo lol6 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -149,19 +149,19 @@ test7: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol7 > /tmp/out echo lol7 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -173,19 +173,19 @@ test8: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol8 > /tmp/out echo lol8 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -197,19 +197,19 @@ test9: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol9 > /tmp/out echo lol9 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
@ -221,19 +221,19 @@ test10: {
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, },
{ {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
echo lol10 > /tmp/out echo lol10 > /tmp/out
"""] """]
dir: "/" dir: "/"
always: true always: true
}, },
{ {
do: "export" do: "export"
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },

View File

@ -3,27 +3,25 @@ package testing
teststring: { teststring: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
echo something > /tmp/out echo something > /tmp/out
""" """,
] ]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },
{ {
do: "export" do: "export"
// Source path in the container // Source path in the container
source: "/tmp/out" source: "/tmp/out"
format: "lalalalal" format: "lalalalal"
}, },
] ]
}
} }

View File

@ -3,18 +3,16 @@ package testing
teststring: { teststring: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "export"
do: "export" // Source path in the container
// Source path in the container source: "/tmp/lalala"
source: "/tmp/lalala" format: "string"
format: "string" },
}, ]
]
}
} }

View File

@ -2,29 +2,27 @@ package testing
test: { test: {
string string
=~ "^NAAAA.+" =~"^NAAAA.+"
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
printf something > /tmp/out printf something > /tmp/out
""" """,
] ]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },
{ {
do: "export" do: "export"
// Source path in the container // Source path in the container
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -1,27 +1,22 @@
package testing package testing
test: { test: #dagger: compute: [
{
#dagger: { do: "fetch-container"
compute: [ ref: "alpine"
{ },
do: "fetch-container" {
ref: "alpine" do: "exec"
}, args: ["sh", "-c", """
{ echo '{"something": "something"}' > /tmp/out
do: "exec" """,
args: ["sh", "-c", """
echo '{"something": "something"}' > /tmp/out
"""
]
dir: "/"
},
{
do: "export"
// Source path in the container
source: "/tmp/out"
format: "json"
},
] ]
} dir: "/"
} },
{
do: "export"
// Source path in the container
source: "/tmp/out"
format: "json"
},
]

View File

@ -3,27 +3,25 @@ package testing
test: { test: {
number number
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
echo -123.5 > /tmp/out echo -123.5 > /tmp/out
""" """,
] ]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },
{ {
do: "export" do: "export"
// Source path in the container // Source path in the container
source: "/tmp/out" source: "/tmp/out"
format: "number" format: "number"
}, },
] ]
}
} }

View File

@ -3,27 +3,25 @@ package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
printf something > /tmp/out printf something > /tmp/out
""" """,
] ]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },
{ {
do: "export" do: "export"
// Source path in the container // Source path in the container
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -2,29 +2,27 @@ package testing
test: { test: {
string string
=~ "^some.+" =~"^some.+"
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
printf something > /tmp/out printf something > /tmp/out
""" """,
] ]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19 // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/" dir: "/"
}, },
{ {
do: "export" do: "export"
// Source path in the container // Source path in the container
source: "/tmp/out" source: "/tmp/out"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -1,29 +1,24 @@
package testing package testing
test: { test: #dagger: compute: [
{
#dagger: { do: "fetch-container"
compute: [ ref: "alpine"
{ },
do: "fetch-container" {
ref: "alpine" do: "exec"
}, args: ["sh", "-c", """
{ echo "--- # Shopping list
do: "exec" [milk, pumpkin pie, eggs, juice]" > /tmp/out
args: ["sh", "-c", """ """,
echo "--- # Shopping list
[milk, pumpkin pie, eggs, juice]" > /tmp/out
"""
]
// XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
dir: "/"
},
{
do: "export"
// Source path in the container
source: "/tmp/out"
format: "yaml"
},
] ]
} // XXX Blocked by https://github.com/blocklayerhq/dagger/issues/19
} dir: "/"
},
{
do: "export"
// Source path in the container
source: "/tmp/out"
format: "yaml"
},
]

View File

@ -1,46 +1,36 @@
package testing package testing
busybox1: { busybox1: #dagger: compute: [
#dagger: compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox"
ref: "busybox" },
}, ]
]
}
busybox2: { busybox2: #dagger: compute: [
#dagger: compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox:latest"
ref: "busybox:latest" },
}, ]
]
}
busybox3: { busybox3: #dagger: compute: [
#dagger: compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox:1.33-musl"
ref: "busybox:1.33-musl" },
}, ]
]
}
busybox4: { busybox4: #dagger: compute: [
#dagger: compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7"
ref: "busybox@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7" },
}, ]
]
}
busybox5: { busybox5: #dagger: compute: [
#dagger: compute: [ {
{ do: "fetch-container"
do: "fetch-container" ref: "busybox:1.33-musl@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7"
ref: "busybox:1.33-musl@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7" },
}, ]
]
}

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine@sha256:c6c7524e2111f22a9f7577211232d89a9e68cf5b9ed4a41ba77957c9771380a5" ref: "alpine@sha256:c6c7524e2111f22a9f7577211232d89a9e68cf5b9ed4a41ba77957c9771380a5"
} },
] ]

View File

@ -4,7 +4,7 @@ package testing
// Once buildkit has pulled that digest, it will stay cached and happily succeed WHATEVER the image name then is // Once buildkit has pulled that digest, it will stay cached and happily succeed WHATEVER the image name then is
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "busyboxaaa@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7" ref: "busyboxaaa@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7"
}, },
] ]

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "doesnotexist" ref: "doesnotexist"
} },
] ]

View File

@ -2,7 +2,7 @@ package testing
#dagger: compute: [ #dagger: compute: [
{ {
do: "fetch-container" do: "fetch-container"
ref: "alpine:doesnotexist" ref: "alpine:doesnotexist"
} },
] ]

View File

@ -1,11 +1,9 @@
package testing package testing
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-git"
do: "fetch-git" remote: "https://github.com/blocklayerhq/acme-clothing.git"
remote: "https://github.com/blocklayerhq/acme-clothing.git" ref: "master"
ref: "master" },
} ]
]
}

View File

@ -1,9 +1,7 @@
package testing package testing
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-git"
do: "fetch-git" },
} ]
]
}

View File

@ -1,11 +1,9 @@
package testing package testing
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-git"
do: "fetch-git" remote: "pork://pork"
remote: "pork://pork" ref: "master"
ref: "master" },
} ]
]
}

View File

@ -1,11 +1,9 @@
package testing package testing
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-git"
do: "fetch-git" remote: "https://github.com/blocklayerhq/acme-clothing.git"
remote: "https://github.com/blocklayerhq/acme-clothing.git" ref: "lalalalal"
ref: "lalalalal" },
} ]
]
}

View File

@ -1,11 +1,9 @@
package testing package testing
#dagger: { #dagger: compute: [
compute: [ {
{ do: "fetch-git"
do: "fetch-git" remote: "https://github.com/blocklayerhq/lalalala.git"
remote: "https://github.com/blocklayerhq/lalalala.git" ref: "master"
ref: "master" },
} ]
]
}

View File

@ -3,35 +3,31 @@ package testing
test1: { test1: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] },
}, {
{ do: "export"
do: "export" source: "/etc/issue"
source: "/etc/issue" format: "string"
format: "string" },
}, ]
]
}
} }
test2: { test2: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "busybox"}]
from: [{do: "fetch-container", ref: "busybox"}] },
}, {
{ do: "export"
do: "export" source: "/etc/issue"
source: "/etc/issue" format: "string"
format: "string" },
}, ]
]
}
} }

View File

@ -1,57 +1,53 @@
package testing package testing
component: #dagger: compute: [{ component: #dagger: compute: [{
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}, { }, {
do: "exec" do: "exec"
args: ["sh", "-c", """ args: ["sh", "-c", """
printf lol > /id printf lol > /id
"""] """]
dir: "/" dir: "/"
}] }]
test1: { test1: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: component
from: component },
}, {
{ do: "export"
do: "export" source: "/id"
source: "/id" format: "string"
format: "string" },
}, ]
]
}
} }
test2: { test2: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: #dagger: compute: [{
from: #dagger: compute: [{ do: "fetch-container"
do: "fetch-container" ref: "alpine"
ref: "alpine" }, {
}, { do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
printf lol > /id printf lol > /id
"""] """]
dir: "/" dir: "/"
}] }]
}, },
{ {
do: "export" do: "export"
source: "/id" source: "/id"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -1,20 +1,17 @@
package testing package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] },
}, {
{ do: "export"
do: "export" source: "/etc/issue"
source: "/etc/issue" format: "string"
format: "string" },
}, ]
]
}
} }

View File

@ -3,25 +3,23 @@ package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
echo "NOT SURE WHAT TO TEST YET" > /out echo "NOT SURE WHAT TO TEST YET" > /out
"""] """]
dir: "/" dir: "/"
mount: something: "cache" mount: something: "cache"
}, },
{ {
do: "export" do: "export"
source: "/out" source: "/out"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -3,31 +3,29 @@ package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
ls -lA /lol > /out ls -lA /lol > /out
"""] """]
dir: "/" dir: "/"
mount: something: { mount: something: {
input: dagger: #compute: [{ input: dagger: #compute: [{
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}] }]
path: "/lol" path: "/lol"
} }
}, },
{ {
do: "export" do: "export"
source: "/out" source: "/out"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -3,31 +3,29 @@ package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
ls -lA /lol > /out ls -lA /lol > /out
"""] """]
dir: "/" dir: "/"
mount: something: { mount: something: {
input: [{ input: [{
do: "fetch-container" do: "fetch-container"
ref: "alpine" ref: "alpine"
}] }]
path: "/lol" path: "/lol"
} }
}, },
{ {
do: "export" do: "export"
source: "/out" source: "/out"
format: "string" format: "string"
}, },
] ]
}
} }

View File

@ -3,25 +3,23 @@ package testing
test: { test: {
string string
#dagger: { #dagger: compute: [
compute: [ {
{ do: "load"
do: "load" from: [{do: "fetch-container", ref: "alpine"}]
from: [{do: "fetch-container", ref: "alpine"}] },
}, {
{ do: "exec"
do: "exec" args: ["sh", "-c", """
args: ["sh", "-c", """
echo "NOT SURE WHAT TO TEST YET" > /out echo "NOT SURE WHAT TO TEST YET" > /out
"""] """]
dir: "/" dir: "/"
mount: something: "tmpfs" mount: something: "tmpfs"
}, },
{ {
do: "export" do: "export"
source: "/out" source: "/out"
format: "string" format: "string"
}, },
] ]
}
} }