[Docker] docker安裝與程序運行


安裝Docker與程序運行

1. requirements.txt

Problem:

Downloading https://files.pythonhosted.org/packages/69/cb/f5be453359271714c01b9bd06126eaf2e368f1fddfff30818754b5ac2328/funcsigs-1.0.2-py2.py3-none-any.whl
Collecting futures==3.2.0 (from -r requirements.txt (line 8))
Could not find a version that satisfies the requirement futures==3.2.0 (from -r requirements.txt (line 8)) (from versions: 0.2.python3, 0.1, 0.2, 1.0, 2.0, 2.1, 2.1.1, 2.1.2, 2.1.3, 2.1.4, 2.1.5, 2.1.6, 2.2.0, 3.0.0, 3.0.1, 3.0.2, 3.0.3, 3.0.4, 3.0.5, 3.1.0, 3.1.1) No matching distribution found for futures==3.2.0 (from -r requirements.txt (line 8)) You are using pip version 10.0.1, however version 18.1 is available. You should consider upgrading via the 'pip install --upgrade pip' command.

Solution:

futures==3.2.0 => futures==3.1.1

2. Install Docker CE for Ubuntu

 https://docs.docker.com/install/linux/docker-ce/ubuntu/

3.  Problem: 

write /var/lib/docker/tmp/GetImageBlob891597147: no space left on device

Solution:

sudo apt-get autoclean   # 刪除你已經卸載掉的軟件包的命令為 

sudo apt-get clean # 若你想清理出更多的空間,可以把電腦上存儲的安裝包全部卸載 sudo apt-get autoremove # 刪除已經被卸載的軟件所依賴的(其他軟件不依賴的)孤立的軟件包

空間仍不足:通過建立軟鏈接將/var目錄下占用空間較大的目錄移動到富足的空間區塊(如/home)下,使得/var下不再占用空間。 (具體實現)

mv /var/cache /home/lsy      #將var下的cache目錄移動到home或者其他空間富足的區塊中

ln -s /home/lsy/cache /var  #/var/cache指向/home/lsy/cache,這樣cache目錄將不再占用/var目錄的空間 mv /var/lib/docker /home/lsy ln -s /home/lsy/docker /var/lib service docker stop service docker start

一定要重啟docker,否則會出現

OCI runtime create failed: /var/lib/docker/overlay2/c6eb60dada971e57fd5d125fb61d294870be347a2efb287862f8dfe52d99c57b/merged is not an absolute path or is a symlink: unknown

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM