Skip to content

Commit

Permalink
Add a "set -e" to the dind-sidecar test script and run the image once.
Browse files Browse the repository at this point in the history
I was bitten by this test not having one, when the "docker build"
failed but we continued on executing anyway. I did a cursory look
at the other tests, and they either already have this or are so
short/simple that it doesn't matter.

Ref tektoncd#3628
  • Loading branch information
Dan Lorenc committed Dec 12, 2020
1 parent bff0ba0 commit 5fa475b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion examples/v1alpha1/taskruns/dind-sidecar.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ spec:
value: /certs/client
script: |
#!/usr/bin/env sh
set -e
# Run a Docker container.
docker run busybox echo hello
Expand All @@ -28,7 +29,7 @@ spec:
RUN apt-get update
ENTRYPOINT ["echo", "hello"]
EOF
docker build -t hello . && docker run hello
docker build -t hello .
docker images
# ...then run it!
Expand Down
3 changes: 2 additions & 1 deletion examples/v1beta1/taskruns/dind-sidecar.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ spec:
value: /certs/client
script: |
#!/usr/bin/env sh
set -e
# Run a Docker container.
docker run busybox echo hello
Expand All @@ -28,7 +29,7 @@ spec:
RUN apt-get update
ENTRYPOINT ["echo", "hello"]
EOF
docker build -t hello . && docker run hello
docker build -t hello .
docker images
# ...then run it!
Expand Down

0 comments on commit 5fa475b

Please sign in to comment.