-
Notifications
You must be signed in to change notification settings - Fork 343
Conversation
@colemickens I am not familiar with Rust. Maybe you could suggest a good mid-size project that I could clone and try, to confirm that the LS works in the full image? |
@@ -110,6 +110,13 @@ RUN ln -s /usr/bin/clangd-6.0 /usr/bin/clangd | |||
RUN apt-get update && apt-get install -y python python-pip | |||
RUN pip install python-language-server | |||
|
|||
#Rust | |||
RUN curl https://sh.rustup.rs -sSf > /tmp/rustup.sh | |||
RUN chmod +x /tmp/rustup.sh && /tmp/rustup.sh -y |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When building the image on my Ubuntu 16.04 machine, I get the following error:
Step 41/53 : RUN chmod +x /tmp/rustup.sh && /tmp/rustup.sh -y
---> Running in 73694bf1a4f1
/bin/sh: 1: /tmp/rustup.sh: Text file busy
The command '/bin/sh -c chmod +x /tmp/rustup.sh && /tmp/rustup.sh -y' returned a non-zero code: 2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replacing the line with RUN /bin/sh /tmp/rustup.sh -y
seems to work for me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand how there could be a difference here, unless something changed in the base image and you have an older base image cached.
I'm using this Dockerfile currently, without issue. Further, I can't imagine a script that /bin/sh
could run that /bin/bash
(presumably the default in Ubuntu) couldn't run.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the issue I encountered may be this one: moby/moby#9547
Nothing wrong as such with your version - technically it should work just as well. However the issue I reported happened consistently on my work laptop. The same Dockerfile builds fine on my (much faster) home desktop. According to the link above, it may be linked to the aufs
storage driver. I do not remember if that's used on my work laptop, but it's not on my desktop, so that may be a factor.
unless something changed in the base image and you have an older base image cached
This image is self-contained and doesn't derive from the base image. I used --no-cache
when building to make sure it was a clean build.
I can't imagine a script that /bin/sh could run that /bin/bash (presumably the default in Ubuntu) couldn't run.
looks like docker is using /bin/sh, so I used the same. from the error message: /bin/sh: 1: /tmp/rustup.sh: Text file busy
. My goal was to avoid having to use chmod before executing the file, thus reducing the two commands to one.
Using a sync
between the chmod
and script execution may be an alternative: moby/moby#9547 (comment)
This user has a theory about what's happening: moby/moby#9547 (comment)
Please sign your commit:
|
@@ -21,6 +21,7 @@ | |||
"@theia/preferences": "latest", | |||
"@theia/process": "latest", | |||
"@theia/python": "latest", | |||
"@theia/rust": "latest", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like @theia/rust is not yet published on npm, correct?
update: it is now
This contribution has been automatically marked as stale due to inactivity, and it will be closed if no further activity occurs. Thank you for contributing to Theia! |
Fixes #48.
Blocked on theia-ide/theia-rust-extension#2