This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
dagger/docs/reference/universe/docker
Tom Chauveau 020c458921 Add project management in compose.#App definition
I found an issue when during tests execution : there was orphan.
It's because #App doesn't give way to specify the compose project,
by default it's the directory where you launch your app but in our
definition, it will always be source.

The problem is that if we launch two differents docker-compose in the same
server, his project name will be source for both and it will create
orphans problems on cleanup (by docker-compose down).

This case is exactly what we do in tests so I've add the field name
to specify the projet name and avoid that issue.

Signed-off-by: Tom Chauveau <tom.chauveau@epitech.eu>
2021-06-26 16:07:14 +02:00
..
compose.md Add project management in compose.#App definition 2021-06-26 16:07:14 +02:00
README.md Update import to new alpha version 2021-06-25 16:56:28 +02:00

sidebar_label
docker

alpha.dagger.io/docker

Docker container operations

import "alpha.dagger.io/docker"

docker.#Build

Build a Docker image from source, using included Dockerfile

docker.#Build Inputs

Name Type Description
source dagger.#Artifact -

docker.#Build Outputs

No output.

docker.#Command

A container image that can run any docker command

docker.#Command Inputs

Name Type Description
command string Command to execute
registries [] Image registries

docker.#Command Outputs

No output.

docker.#ImageFromDockerfile

Build a Docker image from the provided Dockerfile contents

docker.#ImageFromDockerfile Inputs

Name Type Description
dockerfile string Dockerfile passed as a string
context dagger.#Artifact Build context

docker.#ImageFromDockerfile Outputs

No output.

docker.#Pull

Pull a docker container

docker.#Pull Inputs

Name Type Description
from string Remote ref (example: "index.docker.io/alpine:latest")

docker.#Pull Outputs

No output.

docker.#Push

Push a docker image

docker.#Push Inputs

Name Type Description
ref string Remote ref (example: "index.docker.io/alpine:latest")
source dagger.#Artifact Image

docker.#Push Outputs

No output.

docker.#Run

docker.#Run Inputs

Name Type Description
ssh.host string ssh host
ssh.user string ssh user
ssh.port *22 | int ssh port
ssh.key dagger.#Secret private key
ref string Image reference (e.g: nginx:alpine)
run.ssh.host string ssh host
run.ssh.user string ssh user
run.ssh.port *22 | int ssh port
run.ssh.key dagger.#Secret private key
run.command """\n # Run detach container\n OPTS=""\n \n if [ ! -z "$CONTAINER_NAME" ]; then\n \tOPTS="$OPTS --name $CONTAINER_NAME"\n fi\n \n docker container run -d $OPTS "$IMAGE_REF"\n """ Command to execute
run.env.IMAGE_REF string -
run.registries [] Image registries

docker.#Run Outputs

No output.