[root@ibt59 bin]# docker-compose -V
[52546] Cannot open self /usr/local/bin/docker-compose or archive /usr/local/bin/docker-compose.pkg
问题解决
# 删除原来不能执行的/usr/local/bin/docker-compose
sudo rm /usr/local/bin/docker-compose
# 下载安装docker-compose
sudo curl -L "https://github.com/docker/compose/releases/download/1.xx.x/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
# 添加权限
sudo chmod +x /usr/local/bin/docker-compose
# 执行
docker-compose -v
具体操作
[root@ibt59 bin]# docker-compose -V
[52546] Cannot open self /usr/local/bin/docker-compose or archive /usr/local/bin/docker-compose.pkg
[root@ibt59 bin]# sudo rm /usr/local/bin/docker-compose
[root@ibt59 bin]# ls
jemalloc-config jemalloc.sh jeprof libmcrypt-config luajit luajit-2.0.4 mcrypt mdecrypt
[root@ibt59 bin]# sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 12.1M 100 12.1M 0 0 106k 0 0:01:56 0:01:56 --:--:-- 100k
[root@ibt59 bin]# sudo chmod +x /usr/local/bin/docker-compose
[root@ibt59 bin]# docker-compose -v
docker-compose version 1.29.2, build 5becea4c
[root@ibt59 bin]# ls
docker-compose jemalloc-config jemalloc.sh jeprof libmcrypt-config luajit luajit-2.0.4 mcrypt mdecrypt
服务器托管,北京服务器托管,服务器租用 http://www.fwqtg.net
机房租用,北京机房租用,IDC机房托管, http://www.e1idc.net