Comments (5)
Curiously enough, hub.docker.io
handles that file, too: https://hub.docker.com/r/psimons/opensuse-docker/builds/bcqiycksrui3xjdd7eh7jmd/. Apparently, the missing \
causes the next shell command to be interpreted as a separate RUN
statement. I have never noticed that; I omitted the \
by accident.
Anyhow, I agree that this behavior is unreliable at best and that it's probably a feature rather than a bug that the parser doesn't accept this code. I committed peti/opensuse-docker@bb78399 to fix my file accordingly. Thank you very much for your help.
from language-docker.
What is your version of docker? I have just tried it on my one and it recognized as invalid Dockefile
$ wget https://raw.githubusercontent.com/peti/opensuse-docker/master/tw-haskell-dev/Dockerfile -q
$ docker --version
Docker version 18.05.0-ce, build f150324
$ docker build -t tw-haskell-dev .
Sending build context to Docker daemon 2.56kB
Error response from daemon: Dockerfile parse error line 18: unknown instruction: &&
from language-docker.
I have Docker version 18.03.1-ce, build 9ee9f402cd1eba817c5591a64f1d770c87c421a4
.
from language-docker.
Hmm I have tried it on Ubuntu VM
# wget https://raw.githubusercontent.com/peti/opensuse-docker/master/tw-haskell-dev/Dockerfile -q
# docker --version
Docker version 18.03.1-ce, build 9ee9f40
# docker build -t tw-haskell-dev .
Sending build context to Docker daemon 2.56kB
Error response from daemon: Dockerfile parse error line 18: unknown instruction: &&
and it still does not work as I would expect. Looks like dark magic (something not in my knowledge) is happening in your environment.
Anyway oneline to multiline should be broken by using \
and if that is ignored it sounds like an issue with docker/moby or OS and will not work on most of installations.
Can you try it somewhere else? Are you able to reproduce this behaviour?
from language-docker.
well, I guess this was a win for the docker file linter!!
I'm closing as there is no action we need to take here.
from language-docker.
Related Issues (20)
- [Feature Request] EXPOSE UDP port *range* HOT 4
- Parse RUN agruments do not respect control operators HOT 1
- Fail to compile language-docker-5.0.1 HOT 2
- Cannot parse if line ends with linebreak and space HOT 2
- 'from "opensuse/tumbleweed"' gives unexpected result HOT 1
- 'label' has to quote arguments HOT 1
- Inaccurate version bounds HOT 2
- #escape=` is not supported HOT 1
- compilation with ghc 8.8.2 stack 15.1 HOT 4
- GHC 8.10.1 build issues
- Pretty printing of `RUN` in shell form replaces multiple spaces in quoted string HOT 1
- sdist doesn't include all necessary files for tests
- Test files missing from release tarball HOT 2
- Add --link flag to COPY/ADD instrructions HOT 1
- Support for heredocs HOT 6
- Wrong escaping of `\` when parsing ENV instructions HOT 1
- prettyPrint does not preseve the content of quoted string
- build errors with ghc-9.8.x
- Add full support for RUN --mount=type=cache flags
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from language-docker.