0x0. Origin:
On a new Fedora 25 today, following official documentation, after installing docker-compose using curl, verify that an error occurred when the installation was successful:
The command used for installation is;
Curl-l https://github.com/docker/compose/releases/download/1.14.0-rc2/docker-compose-' uname-s '-' ur/local/bin/ Docker-compose
chmod +x/usr/local/bin/docker-compose
I try to set the file to 777 permissions as well as not solve the problem.
[email protected] bin]# LL
Total 8076
-rwxrwxrwx. 1 root root 8268354 June 14:58 docker-compose
Error:
[Email protected] bin]#./docker-compose
Cannot open Self/usr/local/bin/docker-compose or archive/usr/local/bin/docker-compose.pkg
0x1. Workaround:
Go to the following URL to download the current version:
Https://github.com/docker/compose/releases/tag/1.14.0-rc2
Page pull to the bottom, download:
Docker-compose-linux-x86_64
Then upload the file to the/usr/local/bin/folder and rename it to Docker-compose, modify the permissions for this file, and add the executable: chmod +x/usr/local/bin/docker-compose
And then run
[Email protected] bin]# Docker-compose version
Docker-compose version 1.14.0-rc2, build 24dae73
Docker-py version:2.3.0
CPython version:2.7.13
OpenSSL Version:openssl 1.0.1t 3 May 2016
You can see that there are no more problems.
0x2. Reason:
Use the methods described in the official documentation:
curl -L https://github.com/docker/compose/releases/download/1.14.0-rc2/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-composechmod +x /usr/local/bin/docker-compose
When installing, the files that curl downloads are incomplete and do not give any error messages. I guess it's the problem with HTTPS, and I didn't dig it.
You can see that the file I downloaded via curl is smaller than the size of the file that was downloaded and uploaded to the server by using a browser:
[email protected] bin]# LL
Total 16164
-rwxr-xr-x. 1 root root 8278064 June 15:21 docker-compose
-rwxrwxrwx. 1 root root 8268354 June 14:58 docker-compose-curl
Workaround for Linux to perform docker-compose version checking for success when installing docker-compose using curl