Jump to content
jackson

HELP: docker-shell script error

4 posts in this topic Last Reply

Recommended Posts

Hi,

 

I followed the instructions in SpaceInvaderOne's recent "How to easily bash into a running docker container" video, but I get the following error when I run #docker-shell 

 

root@SERVER:~# docker-shell
-bash: /usr/local/bin/docker-shell: /bin/bash^M: bad interpreter: No such file or directory

 

Has anyone seen this before or know what's causing it?

 

Thanks!

 

 

Share this post


Link to post

I ended up dealing with it by downloading his docker-shell file in the description and then copying it onto the flash disk, then using the Command Line plugin and the Custom Tab plugin to run a shell inside the unRAID GUI. I then put the go file in a share and used vi to add the cp /boot/custom/docker-shell /usr/local/bin line. Then moved the go file from the share to the flash disk and ran #cp /boot/custom/docker-shell /usr/local/bin in shell. It worked after that. I'm guessing Windows was doing something weird with line breaks... Was very annoying, but at least it's sorted out now. I hope this helps anyone else who was having this same issue!

Share this post


Link to post
10 hours ago, jackson said:

I'm guessing Windows was doing something weird with line breaks...

Perfectly normal.  Windows uses \r\n for line breaks, whereas everything else in the world uses \n.  The solution is that anything you utilize with unRaid is to save the file with Notepad++ and set it to use Unix style line endings.

Share this post


Link to post
17 hours ago, Squid said:

Perfectly normal.  Windows uses \r\n for line breaks, whereas everything else in the world uses \n.  The solution is that anything you utilize with unRaid is to save the file with Notepad++ and set it to use Unix style line endings.

 

Thanks, Squid!

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now