Docker machine install syntax error near unexpected token ‘newline’! DOCTYPE HTML problem resolution

Recently learned that the host management docker – machine this chapter, https://blog.csdn.net/CloudMan6/article/details/75810234 according to the article to learn,
To recommend a lot on learning docker website at https://github.com/llitfkitfk/docker-tutorial-cn
System: Ubuntu 14.04
Docker: 18.06.0 – ce
There was a problem with the installation and the command was as follows:

The curl -l https://github.com/docker/machine/releases/download/v0.9.0/docker-machine- ` ` uname – s – ` uname -m ` & gt; /tmp/docker-machine & &
chmod +x /tmp/docker-machine & &
sudo cp /tmp/docker-machine /usr/local/bin/docker-machine

His version was a little old, so I just changed v0.14.0 without considering anything else. The installation process is as follows. I was ordered to execute three separate orders,

The docker-machine file appears in the /usr/local/bin directory
View the version information to verify that the installation was successful. Run the command Docker-Machine version and find an error

When I look at the contents of the file, I see no problem. I suspect it’s A newline. Cat-a filename finds that the newline is $.
Also tried running the %s/^M//g command with the ^M tail removed. It could also be ‘< > ‘, but the HTML5 header can’t be deleted.

I found a way to install the website. No matter what I learn, I like the documents on the official website very much, because he is the most formal.
https://docs.docker.com/machine/install-machine/
If you are running on Linux:

$base=https://github.com/docker/machine/releases/download/v0.14.0 & amp; &
curl -L $base/docker-machine-$(uname -s)-$(uname -m) > /tmp/docker-machine & &
sudo install/TMP /docker-machine /usr/local/bin/docker-machine

I still have three commands to run, either replacing $bash with the url above, or simply accessing and pasting it directly in the host browser.
The installation process is as follows. Unlike above, it takes a little time and looks a lot more obvious.

Then it was time to witness the miracle. That’s it. I’ve finally installed it.

If you look at the files in /usr/local/bin, the contents are different. I’m finally ready to move on.

 
 


Read More: