Replying to @⁨drq@mastodon.ml⁩

@drq well… # in Dockerfile denotes comments already, meaning that shebang mechanism can work just fine with a simple wrapper script with no hackery that would ignore the file's first line.

Someone's even done it already: github.com/JakeWharton/dockerf

Treat your Dockerfiles as self-contained, editable scripts - JakeWharton/dockerfile-shebangGitHubGitHub - JakeWharton/dockerfile-shebang: Treat your Dockerfiles as self-contained, editable scriptsTreat your Dockerfiles as self-contained, editable scripts - JakeWharton/dockerfile-shebang
ru