You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[gen-dockerfile] Make /code directory creation idempotent (#1956)
## Summary
Resolves:
- #1953
- #1930
## How was it tested?
* Note: I don't recommend applying the patch below used to test this PR.
Building an actual Dockerfile is way more of an integration test and I
feel it is out of scope.
```diff
diff --git a/testscripts/generate/dockerfile.test.txt b/testscripts/generate/dockerfile.test.txt
index d63680b..ec561564 100644
--- a/testscripts/generate/dockerfile.test.txt
+++ b/testscripts/generate/dockerfile.test.txt
@@ -1,3 +1,5 @@
exec devbox init
exec devbox generate dockerfile
exists Dockerfile
+exec devbox add docker
+exec devbox run -- docker build .
```
Followed by:
```shell
$ go test ./testscripts -run TestScripts/dockerfile
```
which results in a successfully built dockerfile.
0 commit comments