cue files: #compute -> #up
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
This commit is contained in:
parent
8a4aa4d42b
commit
c16455249e
@ -10,7 +10,7 @@ let defaultVersion = "3.13.2@sha256:a75afd8b57e7f34e4dad8d65e2c7ba2e1975c795ce1e
|
||||
package: [string]: true | false | string
|
||||
version: string | *defaultVersion
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#FetchContainer & {
|
||||
ref: "index.docker.io/alpine:\(version)"
|
||||
},
|
||||
|
@ -18,7 +18,7 @@ import (
|
||||
|
||||
// Re-usable aws-cli component
|
||||
#CLI: {
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: alpine.#Image & {
|
||||
package: bash: "=5.1.0-r0"
|
||||
|
@ -46,7 +46,7 @@ import (
|
||||
|
||||
outputs: [string]: string
|
||||
|
||||
outputs: #compute: [
|
||||
outputs: #up: [
|
||||
llb.#Load & {
|
||||
from: aws.#CLI
|
||||
},
|
||||
|
@ -21,7 +21,7 @@ import (
|
||||
kubeconfig: {
|
||||
dagger.#Secret
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: aws.#CLI
|
||||
},
|
||||
|
@ -7,7 +7,7 @@ import (
|
||||
// An artifact such as source code checkout, container image, binary archive...
|
||||
// May be passed as user input, or computed by a buildkit pipeline
|
||||
#Artifact: {
|
||||
#up: llb.#Pipeline
|
||||
#up: [...llb.#Op]
|
||||
_
|
||||
...
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ import (
|
||||
#Build: {
|
||||
source: dagger.#Artifact
|
||||
|
||||
image: #compute: [
|
||||
image: #up: [
|
||||
llb.#DockerBuild & {context: source},
|
||||
]
|
||||
}
|
||||
@ -22,14 +22,14 @@ import (
|
||||
// image may be a remote image ref, or a computed artifact
|
||||
{
|
||||
image: #Ref
|
||||
out: #compute: [
|
||||
out: #up: [
|
||||
llb.#FetchContainer & {ref: image},
|
||||
llb.#Exec & {"args": args},
|
||||
]
|
||||
|
||||
} | {
|
||||
image: _
|
||||
out: #compute: [
|
||||
out: #up: [
|
||||
llb.#Load & {from: image},
|
||||
llb.#Exec & {"args": args},
|
||||
]
|
||||
|
@ -11,7 +11,7 @@ import (
|
||||
permissions: int | *0o644
|
||||
contents: string | bytes
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#WriteFile & {dest: filename, content: contents, mode: permissions},
|
||||
]
|
||||
}
|
||||
@ -24,7 +24,7 @@ import (
|
||||
|
||||
orig: (#read & {path: filename, "from": from}).data
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#WriteFile & {dest: filename, content: "\(orig)\(contents)", mode: permissions},
|
||||
]
|
||||
}
|
||||
@ -40,7 +40,7 @@ import (
|
||||
from: dagger.#Artifact
|
||||
data: {
|
||||
string
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {"from": from},
|
||||
llb.#Export & {source: path},
|
||||
]
|
||||
@ -62,7 +62,7 @@ _#glob: {
|
||||
data: {
|
||||
string
|
||||
_tmppath: "/tmp/ls.out"
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {"from": from},
|
||||
llb.#Exec & {
|
||||
args: ["sh", "-c", "ls \(glob) > \(_tmppath)"]
|
||||
|
@ -10,7 +10,7 @@ import (
|
||||
remote: string
|
||||
ref: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#FetchGit & {
|
||||
"remote": remote
|
||||
"ref": ref
|
||||
|
@ -18,7 +18,7 @@ import (
|
||||
// Environment variables
|
||||
env: [string]: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#FetchContainer & {
|
||||
ref: "docker.io/golang:\(version)-alpine"
|
||||
},
|
||||
@ -63,7 +63,7 @@ import (
|
||||
|
||||
env: [string]: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Copy & {
|
||||
from: #Go & {
|
||||
"version": version
|
||||
|
@ -50,7 +50,7 @@ import (
|
||||
// Kubectl version
|
||||
kubectlVersion: *"v1.19.9" | string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: kubernetes.#Kubectl & {
|
||||
version: kubectlVersion
|
||||
|
@ -17,7 +17,7 @@ import (
|
||||
}
|
||||
"""#
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: alpine.#Image & {
|
||||
package: bash: "=5.1.0-r0"
|
||||
@ -62,7 +62,7 @@ import (
|
||||
kubectl --namespace "$KUBE_NAMESPACE" apply -R -f /source
|
||||
"""#
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: #Kubectl & {"version": version}
|
||||
},
|
||||
|
@ -15,9 +15,6 @@ package llb
|
||||
#Mkdir |
|
||||
#DockerBuild
|
||||
|
||||
// Pipeline is a series of operations
|
||||
#Pipeline: [...llb.#Op]
|
||||
|
||||
// Export a value from fs state to cue
|
||||
#Export: {
|
||||
do: "export"
|
||||
|
@ -42,7 +42,7 @@ import (
|
||||
// Logs URL for this deployment
|
||||
logsUrl: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: alpine.#Image & {
|
||||
package: bash: "=~5.1"
|
||||
|
@ -21,7 +21,7 @@ import (
|
||||
// Set these environment variables during the build
|
||||
env?: [string]: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {
|
||||
from: alpine.#Image & {
|
||||
package: bash: "=~5.1"
|
||||
|
@ -5,7 +5,7 @@ import "dagger.io/llb"
|
||||
foo: "value"
|
||||
bar: "another value"
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#FetchContainer & {ref: "busybox"},
|
||||
llb.#Exec & {args: ["true"]},
|
||||
]
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
A: {
|
||||
result: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -28,7 +28,7 @@ A: {
|
||||
B: {
|
||||
result: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
A: {
|
||||
result: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -28,7 +28,7 @@ A: {
|
||||
B: {
|
||||
result: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -5,7 +5,7 @@ import "encoding/json"
|
||||
A: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -32,7 +32,7 @@ unmarshalled: json.Unmarshal(A)
|
||||
B: {
|
||||
result: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -18,7 +18,7 @@ _expected: """
|
||||
|
||||
TestIgnore: {
|
||||
string
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: ["sh", "-c", "ls /src/* > /out.txt"]
|
||||
|
@ -5,7 +5,7 @@ X1=in: string | *"default input"
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -5,7 +5,7 @@ X1=in: string
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,3 +1,3 @@
|
||||
package testing
|
||||
|
||||
#compute: true
|
||||
#up: true
|
||||
|
@ -1,3 +1,3 @@
|
||||
package testing
|
||||
|
||||
#compute: 123
|
||||
#up: 123
|
||||
|
@ -1,3 +1,3 @@
|
||||
package testing
|
||||
|
||||
#compute: "whatever"
|
||||
#up: "whatever"
|
||||
|
@ -1,3 +1,3 @@
|
||||
package testing
|
||||
|
||||
#compute: whatever: "wrong"
|
||||
#up: whatever: "wrong"
|
||||
|
@ -2,5 +2,5 @@ package testing
|
||||
|
||||
// no-op, should not error
|
||||
empty: {
|
||||
#compute: []
|
||||
#up: []
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ new_prop: "lala"
|
||||
new_prop_too: string
|
||||
#new_def_too: string
|
||||
|
||||
#compute: [{
|
||||
#up: [{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
},
|
||||
|
@ -7,7 +7,7 @@ foo: {
|
||||
new_prop_too: string
|
||||
#new_def_too: string
|
||||
|
||||
#compute: [{
|
||||
#up: [{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
},
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
|
4
tests/llb/copy/invalid/cache/main.cue
vendored
4
tests/llb/copy/invalid/cache/main.cue
vendored
@ -3,7 +3,7 @@ package testing
|
||||
test1: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
@ -25,7 +25,7 @@ test1: {
|
||||
test2: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
component: #compute: [{
|
||||
component: #up: [{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
}, {
|
||||
@ -14,7 +14,7 @@ component: #compute: [{
|
||||
test1: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
@ -36,14 +36,14 @@ test1: {
|
||||
test2: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
},
|
||||
{
|
||||
do: "copy"
|
||||
from: #compute: [{
|
||||
from: #up: [{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
}, {
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
|
@ -8,7 +8,7 @@ import (
|
||||
// Set to `--input-dir=./tests/dockerbuild/testdata`
|
||||
TestData: dagger.#Artifact
|
||||
|
||||
TestInlinedDockerfile: #compute: [
|
||||
TestInlinedDockerfile: #up: [
|
||||
llb.#DockerBuild & {
|
||||
dockerfile: """
|
||||
FROM alpine:latest@sha256:ab00606a42621fb68f2ed6ad3c88be54397f981a7b70a79db3d1172b11c4367d
|
||||
@ -17,7 +17,7 @@ TestInlinedDockerfile: #compute: [
|
||||
},
|
||||
]
|
||||
|
||||
TestOpChaining: #compute: [
|
||||
TestOpChaining: #up: [
|
||||
llb.#DockerBuild & {
|
||||
dockerfile: """
|
||||
FROM alpine:latest@sha256:ab00606a42621fb68f2ed6ad3c88be54397f981a7b70a79db3d1172b11c4367d
|
||||
@ -29,7 +29,7 @@ TestOpChaining: #compute: [
|
||||
},
|
||||
]
|
||||
|
||||
TestBuildContext: #compute: [
|
||||
TestBuildContext: #up: [
|
||||
llb.#DockerBuild & {
|
||||
context: TestData
|
||||
},
|
||||
@ -38,7 +38,7 @@ TestBuildContext: #compute: [
|
||||
},
|
||||
]
|
||||
|
||||
TestBuildContextAndDockerfile: #compute: [
|
||||
TestBuildContextAndDockerfile: #up: [
|
||||
llb.#DockerBuild & {
|
||||
context: TestData
|
||||
dockerfile: """
|
||||
@ -51,7 +51,7 @@ TestBuildContextAndDockerfile: #compute: [
|
||||
},
|
||||
]
|
||||
|
||||
TestDockerfilePath: #compute: [
|
||||
TestDockerfilePath: #up: [
|
||||
llb.#DockerBuild & {
|
||||
context: TestData
|
||||
dockerfilePath: "./dockerfilepath/Dockerfile.custom"
|
||||
@ -61,7 +61,7 @@ TestDockerfilePath: #compute: [
|
||||
},
|
||||
]
|
||||
|
||||
TestBuildArgs: #compute: [
|
||||
TestBuildArgs: #up: [
|
||||
llb.#DockerBuild & {
|
||||
dockerfile: """
|
||||
FROM alpine:latest@sha256:ab00606a42621fb68f2ed6ad3c88be54397f981a7b70a79db3d1172b11c4367d
|
||||
@ -73,7 +73,7 @@ TestBuildArgs: #compute: [
|
||||
]
|
||||
|
||||
// FIXME: this doesn't test anything beside not crashing
|
||||
TestBuildLabels: #compute: [
|
||||
TestBuildLabels: #up: [
|
||||
llb.#DockerBuild & {
|
||||
dockerfile: """
|
||||
FROM alpine:latest@sha256:ab00606a42621fb68f2ed6ad3c88be54397f981a7b70a79db3d1172b11c4367d
|
||||
@ -83,7 +83,7 @@ TestBuildLabels: #compute: [
|
||||
]
|
||||
|
||||
// FIXME: this doesn't test anything beside not crashing
|
||||
TestBuildPlatform: #compute: [
|
||||
TestBuildPlatform: #up: [
|
||||
llb.#DockerBuild & {
|
||||
dockerfile: """
|
||||
FROM alpine:latest@sha256:ab00606a42621fb68f2ed6ad3c88be54397f981a7b70a79db3d1172b11c4367d
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
2
tests/llb/exec/env/invalid/main.cue
vendored
2
tests/llb/exec/env/invalid/main.cue
vendored
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
2
tests/llb/exec/env/overlay/main.cue
vendored
2
tests/llb/exec/env/overlay/main.cue
vendored
@ -2,7 +2,7 @@ package testing
|
||||
|
||||
bar: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
2
tests/llb/exec/env/valid/main.cue
vendored
2
tests/llb/exec/env/valid/main.cue
vendored
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
hello: "world"
|
||||
bar: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
hello: "world"
|
||||
bar: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -2,7 +2,7 @@ package def
|
||||
|
||||
#dang: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -4,7 +4,7 @@ import (
|
||||
"dagger.io/def"
|
||||
)
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load",
|
||||
from: def
|
||||
|
@ -2,7 +2,7 @@ package nonoptional
|
||||
|
||||
dang: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -4,7 +4,7 @@ import (
|
||||
"dagger.io/nonoptional"
|
||||
)
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load",
|
||||
from: nonoptional
|
||||
|
@ -2,7 +2,7 @@ package optional
|
||||
|
||||
dang?: string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -4,7 +4,7 @@ import (
|
||||
"dagger.io/optional"
|
||||
)
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load",
|
||||
from: optional
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
bool
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test1: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -27,7 +27,7 @@ test1: {
|
||||
test2: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -51,7 +51,7 @@ test2: {
|
||||
test3: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -75,7 +75,7 @@ test3: {
|
||||
test4: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -99,7 +99,7 @@ test4: {
|
||||
test5: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -123,7 +123,7 @@ test5: {
|
||||
test6: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -147,7 +147,7 @@ test6: {
|
||||
test7: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -171,7 +171,7 @@ test7: {
|
||||
test8: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -195,7 +195,7 @@ test8: {
|
||||
test9: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -219,7 +219,7 @@ test9: {
|
||||
test10: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
float
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
teststring: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
teststring: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -4,7 +4,7 @@ test: {
|
||||
string
|
||||
=~"^NAAAA.+"
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
testScalar: {
|
||||
bool
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -25,7 +25,7 @@ testScalar: {
|
||||
]
|
||||
}
|
||||
|
||||
testMap: #compute: [
|
||||
testMap: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -50,7 +50,7 @@ testMap: #compute: [
|
||||
// testList: {
|
||||
// [...string]
|
||||
|
||||
// #compute: [
|
||||
// #up: [
|
||||
// {
|
||||
// do: "fetch-container"
|
||||
// ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
number
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -4,7 +4,7 @@ test: {
|
||||
string
|
||||
=~"^some.+"
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
testScalar: {
|
||||
bool
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
@ -30,7 +30,7 @@ testScalar: {
|
||||
// testList: {
|
||||
// [...string]
|
||||
|
||||
// #compute: [
|
||||
// #up: [
|
||||
// {
|
||||
// do: "fetch-container"
|
||||
// ref: "alpine"
|
||||
@ -54,7 +54,7 @@ testScalar: {
|
||||
// ]
|
||||
// }
|
||||
|
||||
testMap: #compute: [
|
||||
testMap: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -1,34 +1,34 @@
|
||||
package testing
|
||||
|
||||
busybox1: #compute: [
|
||||
busybox1: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox"
|
||||
},
|
||||
]
|
||||
|
||||
busybox2: #compute: [
|
||||
busybox2: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox:latest"
|
||||
},
|
||||
]
|
||||
|
||||
busybox3: #compute: [
|
||||
busybox3: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox:1.33-musl"
|
||||
},
|
||||
]
|
||||
|
||||
busybox4: #compute: [
|
||||
busybox4: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7"
|
||||
},
|
||||
]
|
||||
|
||||
busybox5: #compute: [
|
||||
busybox5: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busybox:1.33-musl@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
},
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine@sha256:c6c7524e2111f22a9f7577211232d89a9e68cf5b9ed4a41ba77957c9771380a5"
|
||||
|
@ -2,7 +2,7 @@ package testing
|
||||
|
||||
// XXX WATCHOUT
|
||||
// Once buildkit has pulled that digest, it will stay cached and happily succeed WHATEVER the image name then is
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "busyboxaaa@sha256:e2af53705b841ace3ab3a44998663d4251d33ee8a9acaf71b66df4ae01c3bbe7"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "doesnotexist"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine:doesnotexist"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-git"
|
||||
remote: "https://github.com/blocklayerhq/acme-clothing.git"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-git"
|
||||
},
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-git"
|
||||
remote: "pork://pork"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-git"
|
||||
remote: "https://github.com/blocklayerhq/acme-clothing.git"
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-git"
|
||||
remote: "https://github.com/blocklayerhq/lalalala.git"
|
||||
|
4
tests/llb/load/invalid/cache/main.cue
vendored
4
tests/llb/load/invalid/cache/main.cue
vendored
@ -3,7 +3,7 @@ package testing
|
||||
test1: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "alpine"}]
|
||||
@ -19,7 +19,7 @@ test1: {
|
||||
test2: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "busybox"}]
|
||||
|
@ -1,6 +1,6 @@
|
||||
package testing
|
||||
|
||||
component: #compute: [{
|
||||
component: #up: [{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
}, {
|
||||
@ -14,7 +14,7 @@ component: #compute: [{
|
||||
test1: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: component
|
||||
@ -30,10 +30,10 @@ test1: {
|
||||
test2: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: #compute: [{
|
||||
from: #up: [{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
}, {
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "alpine"}]
|
||||
|
2
tests/llb/mounts/valid/cache/main.cue
vendored
2
tests/llb/mounts/valid/cache/main.cue
vendored
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "alpine"}]
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "alpine"}]
|
||||
@ -13,7 +13,7 @@ test: {
|
||||
args: ["sh", "-c", """
|
||||
cat /mnt/test/lol > /out
|
||||
"""]
|
||||
mount: "/mnt/test": from: #compute: [
|
||||
mount: "/mnt/test": from: #up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "alpine"}]
|
||||
|
@ -3,7 +3,7 @@ package testing
|
||||
test: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "load"
|
||||
from: [{do: "fetch-container", ref: "alpine"}]
|
||||
|
@ -9,7 +9,7 @@ TestPushContainer: {
|
||||
// Generate a random number
|
||||
random: {
|
||||
string
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: ["sh", "-c", "echo -n $RANDOM > /rand"]
|
||||
@ -23,7 +23,7 @@ TestPushContainer: {
|
||||
// Push an image with a random tag
|
||||
push: {
|
||||
ref: "daggerio/ci-test:\(random)"
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#WriteFile & {
|
||||
content: random
|
||||
dest: "/rand"
|
||||
@ -35,14 +35,14 @@ TestPushContainer: {
|
||||
}
|
||||
|
||||
// Pull the image back
|
||||
pull: #compute: [
|
||||
pull: #up: [
|
||||
llb.#FetchContainer & {
|
||||
ref: push.ref
|
||||
},
|
||||
]
|
||||
|
||||
// Check the content
|
||||
check: #compute: [
|
||||
check: #up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: [
|
||||
|
@ -3,7 +3,7 @@ package main
|
||||
hello: {
|
||||
string
|
||||
|
||||
#compute: [
|
||||
#up: [
|
||||
{
|
||||
do: "fetch-container"
|
||||
ref: "alpine"
|
||||
|
@ -11,7 +11,7 @@ TestImageVersion: {
|
||||
version: "3.10.6"
|
||||
}
|
||||
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: image},
|
||||
llb.#Exec & {
|
||||
args: [
|
||||
@ -31,7 +31,7 @@ TestPackageInstall: {
|
||||
package: curl: "=~7.74.0"
|
||||
}
|
||||
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: image},
|
||||
llb.#Exec & {
|
||||
args: ["jq", "--version"]
|
||||
|
@ -14,7 +14,7 @@ TestCreate: {
|
||||
contents: _content
|
||||
}
|
||||
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: [
|
||||
@ -37,7 +37,7 @@ TestRead: {
|
||||
filename: "/etc/alpine-release"
|
||||
from: alpine.#Image & {version: "3.10.6"}
|
||||
}
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: [
|
||||
@ -63,7 +63,7 @@ TestRead2: {
|
||||
from: write
|
||||
}
|
||||
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: [
|
||||
|
@ -15,7 +15,7 @@ TestGoBuild: {
|
||||
output: "/bin/testbin"
|
||||
}
|
||||
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: [
|
||||
|
@ -10,7 +10,7 @@ TestNetlify: {
|
||||
// Generate a random number
|
||||
random: {
|
||||
string
|
||||
#compute: [
|
||||
#up: [
|
||||
llb.#Load & {from: alpine.#Image},
|
||||
llb.#Exec & {
|
||||
args: ["sh", "-c", "echo -n $RANDOM > /rand"]
|
||||
@ -22,7 +22,7 @@ TestNetlify: {
|
||||
}
|
||||
|
||||
// Generate a website containing the random number
|
||||
html: #compute: [
|
||||
html: #up: [
|
||||
llb.#WriteFile & {
|
||||
content: random
|
||||
dest: "index.html"
|
||||
@ -36,7 +36,7 @@ TestNetlify: {
|
||||
}
|
||||
|
||||
// Check if the deployed site has the random marker
|
||||
check: #compute: [
|
||||
check: #up: [
|
||||
llb.#Load & {
|
||||
from: alpine.#Image & {
|
||||
package: bash: "=~5.1"
|
||||
|
@ -14,7 +14,7 @@ TestYarn: {
|
||||
source: TestData
|
||||
}
|
||||
|
||||
test: #compute: [
|
||||
test: #up: [
|
||||
llb.#Load & {from: alpine.#Image & {
|
||||
package: bash: "=5.1.0-r0"
|
||||
}},
|
||||
|
Reference in New Issue
Block a user