Update Docker #Build to incorporate image from Dockerfile

Signed-off-by: Kevin Poirot <kevin@vazee.fr>
This commit is contained in:
Kevin Poirot
2021-09-14 09:54:09 +02:00
parent 4d45e269e0
commit 3e14920062
6 changed files with 21 additions and 45 deletions

View File

@@ -31,12 +31,12 @@ TestBuild: {
TestSourceImageFromDockerfile: dagger.#Artifact @dagger(input)
TestImageFromDockerfile: {
image: #ImageFromDockerfile & {
image: #Build & {
dockerfile: """
FROM alpine
COPY test.txt /test.txt
"""
context: TestSourceImageFromDockerfile
source: TestSourceImageFromDockerfile
}
verify: #up: [

View File

@@ -17,12 +17,12 @@ TestPush: {
target: "daggerio/ci-test:\(tag.out)"
image: #ImageFromDockerfile & {
image: #Build & {
dockerfile: """
FROM alpine
RUN echo "test" > /test.txt
"""
context: ""
source: ""
}
push: #Push & {

View File

@@ -18,12 +18,12 @@ TestResources: {
// Seed is used to force buildkit execution and not simply use a previous generated string.
suffix: random.#String & {seed: "docker multi registry"}
image: #ImageFromDockerfile & {
image: #Build & {
dockerfile: """
FROM alpine
RUN echo "test" > /test.txt
"""
context: ""
source: ""
}
}

View File

@@ -17,12 +17,12 @@ TestPush: {
target: "daggerio/ci-test:\(tag.out)"
image: #ImageFromDockerfile & {
image: #Build & {
dockerfile: """
FROM alpine
RUN echo "test" > /test.txt
"""
context: ""
source: ""
}
push: #Push & {