4 ms·
`COPY --chmod` is quite new, and as mentioned in the post requires BuildKit (i.e. `docker buildx`). A more portable solution is to use `chmod` right after unzi
by hddqsb 5y ago
`COPY --chmod` is quite new, and as mentioned in the post requires BuildKit (i.e. `docker buildx`).
A more portable solution is to use `chmod` right after unzipping the binary. The `COPY` command will then preserve the executable permission.
- dicknuckle 5y agoReally thought I missed something with COPY --chmod so I'm glad you mentioned it's new. COPY's preservation of flags simplified one of projects because I started setting flags on shell scripts in the repo instead of at build time.