mirror of
https://github.com/morten-olsen/morten-olsen.github.io.git
synced 2026-02-08 01:46:28 +01:00
update
This commit is contained in:
48
cue.mod/pkg/universe.dagger.io/docker/cli/test/run.cue
generated
Executable file
48
cue.mod/pkg/universe.dagger.io/docker/cli/test/run.cue
generated
Executable file
@@ -0,0 +1,48 @@
|
||||
package test
|
||||
|
||||
import (
|
||||
"dagger.io/dagger"
|
||||
|
||||
"universe.dagger.io/alpine"
|
||||
"universe.dagger.io/docker"
|
||||
"universe.dagger.io/docker/cli"
|
||||
)
|
||||
|
||||
dagger.#Plan & {
|
||||
client: network: "unix:///var/run/docker.sock": connect: dagger.#Socket
|
||||
|
||||
actions: test: {
|
||||
run: cli.#Run & {
|
||||
host: client.network."unix:///var/run/docker.sock".connect
|
||||
command: name: "info"
|
||||
}
|
||||
|
||||
differentImage: {
|
||||
_cli: docker.#Build & {
|
||||
steps: [
|
||||
alpine.#Build & {
|
||||
packages: "docker-cli": {}
|
||||
},
|
||||
docker.#Run & {
|
||||
command: {
|
||||
name: "sh"
|
||||
flags: "-c": "echo -n foobar > /test.txt"
|
||||
}
|
||||
},
|
||||
]
|
||||
}
|
||||
run: cli.#Run & {
|
||||
input: _cli.output
|
||||
host: client.network."unix:///var/run/docker.sock".connect
|
||||
command: {
|
||||
name: "docker"
|
||||
args: ["info"]
|
||||
}
|
||||
export: files: "/test.txt": "foobar"
|
||||
}
|
||||
}
|
||||
|
||||
// FIXME: test remote connections with `docker:dind` image
|
||||
// when we have long running tasks
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user