如何手动在linux unbutu 上面安装docker
2017-04-25 00:00
387 查看
一 首先下载二进制文件
https://test.docker.com/builds/Linux/x86_64/docker-17.05.0-ce-rc1.tgzhttps://github.com/moby/moby/releases 里面找Downloads
deb/rpm install:
curl -fsSL https://get.docker.com/ | sh
Linux 64bits tgz: https://get.docker.com/builds/Linux/x86_64/docker-17.04.0-ce.tgz
Darwin/OSX 64bits client tgz: https://get.docker.com/builds/Darwin/x86_64/docker-17.04.0-ce.tgz
Linux 32bits arm tgz: https://get.docker.com/builds/Linux/armel/docker-17.04.0-ce.tgz
Windows 64bits zip: https://get.docker.com/builds/Windows/x86_64/docker-17.04.0-ce.zip
Windows 32bits client zip: https://get.docker.com/builds/Windows/i386/docker-17.04.0-ce.zip
二 根据文档安装docker
参考https://docs.docker.com/engine/installation/binaries/#install-daemon-and-client-binaries-on-linuxInstall Docker from binaries
Estimated reading time: 5 minutesNote: You may have been redirected to this page because there is no longer a dynamically-linked Docker package for your Linux distribution.
If you want to try Docker or use it in a testing environment, but you’re not on a supported platform, you can try installing from static binaries. If possible, you should use packages built for your operating system, and use your operating system’s package management system to manage Docker installation and upgrades. Be aware that 32-bit static binary archives do not include the Docker daemon.
Static binaries for the Docker daemon binary are only available for Linux (as
dockerd) and Windows Server 2016 or Windows 10 (as
dockerd.exe). Static binaries for the Docker client are available for Linux and macOS (as
docker), and Windows Server 2016 or Windows 10 (as
docker.exe).
Install daemon and client binaries on Linux
Prerequisites
Before attempting to install Docker from binaries, be sure your host machine meets the prerequisites:A 64-bit installation
Version 3.10 or higher of the Linux kernel. The latest version of the kernel available for you platform is recommended.
iptablesversion 1.4 or higher
gitversion 1.7 or higher
A
psexecutable, usually provided by
procpsor a similar package.
XZ Utils 4.9 or higher
a properly mounted
cgroupfshierarchy; a single, all-encompassing
cgroupmount point is not sufficient. See Github issues #2683,#3485, #4568).
SECURE YOUR ENVIRONMENT AS MUCH AS POSSIBLE
OS considerationsEnable SELinux or AppArmor if possible.
It is recommended to use AppArmor or SELinux if your Linux distribution supports either of the two. This helps improve security and blocks certain types of exploits. Review the documentation for your Linux distribution for instructions for enabling and configuring AppArmor or SELinux.
Warning: If either of the security mechanisms is enabled, do not disable it as a work-around to make Docker or its containers run. Instead, configure it correctly to fix any problems.
Docker daemon considerations
Enable
seccompsecurity profiles if possible. See Enabling
seccompfor Docker.
Enable user namespaces if possible. See the Daemon user namespace options.
Install static binaries
Download the static binary archive. You can download either the latest release binaries or a specific version. To find the download link, see the release notes for the version of Docker you want to install. You can choose atar.gzarchive or
ziparchive.
Extract the archive using
taror
unzip, depending on the format you downloaded. The
dockerdand
dockerbinaries are extracted.
$ tar xzvf /path/to/<FILE>.tar.gz
$ unzip /path/to/<FILE>.zip
Optional: Move the binaries to a directory on your executable path, such as
/usr/bin/. If you skip this step, you must provide the path to the executable when you invoke
dockeror
dockerdcommands.
$ sudo cp docker/* /usr/bin/ ##如果你是手动安装需要做这一步,添加到PATH路径下面
Start the Docker daemon:
$ sudo dockerd &If you need to start the daemon with additional options, modify the above command accordingly.
Verify that Docker is installed correctly by running the
hello-worldimage.
$ sudo docker run hello-worldThis command downloads a test image and runs it in a container. When the container runs, it prints an informational message and exits.
Next steps
Continue to Post-installation steps for LinuxContinue with the User Guide.
相关文章推荐
- 如何在Linux下手动安装mongodb
- 如何装虚拟机及在上面安装LINUX操作系统(转载)
- Linux的Docker上如何安装MySQL
- linux的docker上如何安装mysql
- 如何手动安装WordPress主题和插件(Linux)
- 如何装虚拟机及在上面安装LINUX操作系统
- 如何在Linux上面安装GCC 4.1.2
- 在各大Linux发行版中如何安装Docker及设置加速器?
- docker 1.7.1 linux 离线手动安装方法
- Linux中Docker安装后如何使用Docker容器
- linux的docker上如何安装mysql
- linux 手动安装docker-machine
- 如何在Linux上面安装GCC 4.1.2
- 如何在ubuntu14.04上面安装OpenCv3.0.0
- Linux如何查找软件安装路径?
- 如何在linux平台安装zint开源库
- linux下如何安装jre并配置环境
- linux下如何安装Apache软件
- 如何在linux中从源代码编译安装nodejs?
- 如何查看linux系统安装了哪些服务?