How to Install Docker on Ubuntu

2、CentOS7 Docker 安装以及基本使用 CentOS7Docker 安装以及基本使用 Docker支持以下的CentOS版本: CentOS 7 (64-bit) CentOS 6.5 (64-bit)或更高的版本 前提条件 目前,CentOS 仅发行版本中的内核支持 Docker。 Docker 运行在 CentOS 7 上,要求系统为64位、系统内核版本为 3.10 以上。 Docker 运行在CentOS-... 阅读详情

Purpose

to install docker on Ubuntu 17.10, while using local aliyun mirrors for docker repository and image-accelerator.

As to Ubuntu 14.04, this article would be helpful also, except some different configurations.

Steps

1. Pre-install dependencies

install some dependencies of docker: apt-transport-https, ca-certificates, curl

sudo apt-get install apt-transport-https ca-certificates curl software-properties-common

2. Add GPG certificate
# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
# using mirror server at aliyun.com
curl -fsSL http://mirrors.aliyun.com/docker-ce/linux/ubuntu/gpg | sudo apt-key add -
3. Add repository
# sudo add-apt-repository \
#       "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
#       $(lsb_release -cs) \
#       stable"
# using mirror server at aliyun.com
sudo add-apt-repository \
    "deb [arch=amd64] http://mirrors.aliyun.com/docker-ce/linux/ubuntu \
    $(lsb_release -cs) stable"
4. Update & Install docker-ce
sudo apt-get -y update
sudo apt-get -y install docker-ce
5. Configure Accelerator for Docker images

First, register account at aliyun.com and login, access: https://cr.console.aliyun.com/#/accelerator
Then, you can get accelerator address like this: https://xxxxxxxx.mirror.aliyuncs.com

After above, you can modify configuration file(/etc/docker/daemon.json) to enable and use the accelerator.

# sudo mkdir -p /etc/docker
sudo tee /etc/docker/daemon.json <<-'EOF'
{
  "registry-mirrors": ["https://xxxxxxxx.mirror.aliyuncs.com"]
}
EOF
sudo systemctl daemon-reload
sudo systemctl restart docker
# As to Ubuntu 14.04, just restart service using command as follows:
# sudo service docker restart
6. Run hello-world and enjoy!

After docker restarted, you can test it by run hello-world image. It could not find the image locally for the first time, then it would search and pull from library at cloud-side(also mirror server at aliyun).

sudo docker run hello-world
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world
ca4f61b1923c: Pull complete sudo docker run hello-world
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world
ca4f61b1923c: Pull complete 
Digest: sha256:
Status: Downloaded newer image for hello-world:latest

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
 1. The Docker client contacted the Docker daemon.
 2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
    (amd64)
 3. The Docker daemon created a new container from that image which runs the
    executable that produces the output you are currently reading.
 4. The Docker daemon streamed that output to the Docker client, which sent it
    to your terminal.

To try something more ambitious, you can run an Ubuntu container with:
 $ docker run -it ubuntu bash

Share images, automate workflows, and more with a free Docker ID:
 https://cloud.docker.com/

For more examples and ideas, visit:
 https://docs.docker.com/engine/userguide/

Digest: sha256:xx...
Status: Downloaded newer image for hello-world:latest

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
 1. The Docker client contacted the Docker daemon.
 2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
    (amd64)
 3. The Docker daemon created a new container from that image which runs the
    executable that produces the output you are currently reading.
 4. The Docker daemon streamed that output to the Docker client, which sent it
    to your terminal.

To try something more ambitious, you can run an Ubuntu container with:
 $ docker run -it ubuntu bash

Share images, automate workflows, and more with a free Docker ID:
 https://cloud.docker.com/

For more examples and ideas, visit:
 https://docs.docker.com/engine/userguide/

Enjoy your docker now ?

Addition

If you want to avoid typing ‘sudo’ everytime when you are using docker commands, you can put the current user into the docker user-group. Just run sudo gpasswd -a ${USER} dockercommand, and it would respond with “Adding user ** to group docker”. After that, you can use docker ps, docker images and other commands directly.

Reference

Docker CE 镜像源站 @ Aliyun.com

How to install Paperless with docker on Ubuntu 20.04 Aliyun Update the repo to get latest versions Install the latest version Set Docker to start on startup Give your user permissions to docker, replacing with your username Test it has installed correctly by getting the docker version Installing Paperles 阅读详情

相关推荐

【python】import pandas as pd用法

是 Python 里最常用的数据分析库之一。 的意思是:导入 pandas 库,并给它起个别名 。这样用起来更简洁: 下面总结 pandas 的常见用法(配例子)。目录🔹 1. 数据结构(1) Series(一维数据,类似于数组 + 标签)(2) DataFrame(二维数据表,类似于 Excel 表格)🔹 2. 数据读写🔹 3. 数据查看🔹 4. 数据选择与索引🔹 5. 数据清洗🔹 6. 数据运算🔹 7. 数据筛选(布尔索引)🔹 8. 分组与聚合🔹 9. 排序 Pandas 常用方

2401_86285609的博客 1531

Centos7下安装Docker--菜鸟教程

一,Docker简介 百科说:Docker 是一个开源的应用容器引擎,让开发者可以打包他们的应用以及依赖包到一个可移植的容器中,然后发布到任何流行的Linux机器上,也可以实现虚拟化,容器是完全使用沙箱机制,相互之间不会有任何接口。 看起来有点雾,用过虚拟机的应该对虚拟化技术有点印象,不知道也没关系,就把它当成轻量级的虚拟机吧(虽然一个是完全虚拟化,一个是操作系统层虚拟化),这个解释到位:ht...

人生百态361 6050

OpenManus本地部署实战:从源码编译到浏览器路径优化全解析

本文详细解析了OpenManus本地部署的全过程,从源码编译到浏览器路径优化。涵盖环境准备、源码获取、模型配置、依赖安装等关键步骤,特别针对Windows系统下的chrome.exe路径修改提供了实用解决方案,帮助开发者高效完成部署并优化性能。

weixin_28826545的博客 379

CentOS7 下Docker最新入门教程 超级详细 (安装以及简单的使用)

1、为什么使用Docker(本人) 最近总是频繁的在新服务器发布项目, 每次发布都需要布置项目所需要的环境特别麻烦,而且还有一台机器需要两个环境的状况 例如:发布java web 项目而言 需要下载安装jdk 和tomcat 安装Docker后只需要几个命令就轻松搞定,还有两个环境的问题,我们有一台服务器需要发布两个java web项目 而有一个项目必须使用jdk1.7 而另一个必须用jdk...

码 1万+

嵌入式SPI总线抽象设计:跨平台驱动与分层解耦实践

SPI(串行外设接口)是嵌入式系统中应用最广泛的同步串行通信协议,其核心价值在于高吞吐、低开销与硬件简洁性。其工作原理基于主从架构、全双工/半双工时序及片选(CS)控制,依赖CPOL/CPHA组合定义四种标准模式。在工程实践中,SPI常面临硬件资源受限、多外设共用总线、MCU平台迁移等挑战,导致驱动复用率低、维护成本高。通过结构体+函数指针实现的分层抽象——将物理总线、协议适配与设备驱动解耦,可显著提升代码可移植性与扩展性。该方法天然支持硬件SPI与GPIO模拟SPI双模式切换,并已在STM32等主流MCU

weixin_42601134的博客 60

debian linux系统安装教程,Debian 10(Buster)安装过程图文详解

Debian 项目发布了它的最新稳定版 Debian 10,其代号是 “Buster”,这个发布版将获得 5 年的支持。Debian 10 可用于 32 位和 64 位系统。这个发布版带来很多新的特色,列出下面一些特色:引入新的 Debian 10 的主题 “FuturePrototype”新版本的电脑桌面环境 GNOME 3.30、Cinnamon 3.8、KDE Plasma 5.14、MAT...

weixin_39864601的博客 4985

服务器不会用?教你ubuntu 安装 docker

🧑‍🍼注意:以下的操作均在root用户中进行。ubuntu下自带了docker的库,不需要添加新的源。但是ubuntu自带的docker版本太低,需要先卸载旧的再安装新的。: 这是 Docker 软件的核心包,用于容器化应用程序和管理容器。: 这是 Docker 引擎的软件包,是 Docker 的核心组件之一。docker.io: 这是 Docker 软件的另一个软件包。containerd: 这是一个用于管理容器的守护进程,通常与 Docker 一起使用。runc。

罗小罗同学的博客 3859

微信小程序 - 最新获取用户昵称 / 头像(wx.getUserProfile 接口被废弃后的代替方案)详细教程,2022 年之后的所有微信小程序,获取用户信息最新详细教程,附带示例源代码

微信小程序wx.getUserProfile接口废了用什么代替,微信小程序wx.getUserProfile不能用了怎么办,wx.getUserProfile失效有什么替代方案吗,微信新规定头像昵称填写最新教程,目前微信小程序最新获取用户头像昵称教程,微信小程序用户头像昵称获取规则调整公告,2022改版后的微信小程序如何获取用户头像和昵称信息,微信小程序官方废弃getUserProfile后如何实现获取用户信息,微信小程序wx.getUserProfile接口返回了默认头像昵称,微信小程序获取用户信息不

🏆 前端领域优质创作者 2万+

How To Install Docker on Ubuntu 20.04

How To Install Docker on Ubuntu 20.04

TAO的博客 1081

百度百科 X-Bk-Token 算法还原

百度百科 X-Bk-Token 算法还原

自成背后的博客 1万+

OpenAI最强编程助手Codex:下载安装、使用指南(含使用方式、提示技巧、趋势)

OpenAI最近上线了最强编程Agent——Codex,一起来看看吧!

Code_流苏:在代码中寻诗意,在实践中觅真知 1万+

How to Install Docker on Ubuntu 18.04 Server

Install Docker Ubuntu Docker is a lightweight operating system-level virtualization solution that allows you to run multiple containers simultaneously on a single host or ac...

每天都有新发现 1043

halcon知识:常见三种模板匹配方法总结

halcon的三种模板匹配方法总结,halcon有三种模板匹配方法:即Component-Based、Gray-Value-Based、Shaped_based,分别是基于组件(或成分、元素)的匹配,基于灰度值的匹配和基于形状的匹配,此外还有变形匹配和三维模型匹配也是分属于前面的大类 本文只对形状匹配做简要说明和补充: Shape_Based匹配方法: 上图介绍的是形状匹配做法的一般流程及模板制作的两种方法。 先要补充点知识:形状匹配常见的有四种情况 一般形状匹配模板shape_model、线性变

gongdiwudu的专栏 4万+

How to install Docker on Ubuntu

Docker currently only runs on 64-bits platforms and requires that the kernal version be no less than 3.10.in this tutorial , i use ubuntu 16.04 and the kernal version is 4.13.0-43-generic you can use ...

weixin_34050005的博客 214

精雕软件(JDpaint) 5.5 绿色版

精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版

Statistics and Machine Learning Toolbox

Statistics and Machine Learning Toolbox(带书签),MATLAB统计学习工具

How to Install Docker on Ubuntu 14.04 LTS

http://www.liquidweb.com/kb/how-to-install-docker-on-ubuntu-14-04-lts/ Docker 101: The Basics I. How To Install Docker on Ubuntu 14.04 LTS II. How To List and Attach to Docker Container

leonpengweicn的专栏 706

VB摄像头监控

该VB模块可对摄像头捕获的画面进行录像等,可在创建的窗口进行控制

How to install docker on ubuntu16.04

1, Add Docker source 1,ADD Docker source: $ sudo apt-get update 2,Add CA certificates:  $ sudo apt-get install apt-transport-https ca-certificates 3,Add GPG Key:  $ sudo apt-key adv

xiaochuju526的专栏 504

最新的sdio 4.0 spec 协议标准 带书签 高清完整PDF版

Part-E1-SDIO-Specification-Ver4.00-Final-120220.pdf:最新的sdio 4.0 spec 协议标准 带书签 高清完整PDF版,包括SDIO 接口的外设,SDIO 接口官方协议等。

How to Install Docker on Ubuntu 22.04

How to Install Docker on Ubuntu 22.04

星宇_大佬养成时的博客 404

How to Install and Use Docker on Ubuntu 16.04

By Hitesh Jethva, Alibaba Cloud Tech Share Author Introduction Docker is an Open Source project (container management service) for developers and system administrators to build,...

weixin_33682719的博客 219

How To Install and Use Docker Compose on Ubuntu 18.04

How To Install and Use Docker Compose on Ubuntu 18.04 Docker Compose is a tool that allows you to define and manage multi-container Docker applications. It uses a YAML file ...

每天都有新发现 310

How to install Docker CE on Ubuntu / Debian / Fedora / Arch / CentOS

How toInstall Docker CE on Ubuntu / Install Docker CE on Debian / Install Docker on Fedora / Install Docker on Arch Linux, and Installing Docker CE on CentOS guide is provided here. Note that older versions of docker ( docker and docker-engine), are no lo.

drivery的专栏 301

How To Install Docker On Ubuntu 13.04 x64 VPS

Introduction In case you're not familiar with Docker, here is the summary of it and its functionality: Docker is an open-source engine which automates the deployment of applications as highly po

花花公子 968

How to install experimental Docker versions on my Ubuntu 16.04 LTS

How to install experimental Docker versions on my Ubuntu 16.04 LTS In order to have bleeding edge docker packages in Ubuntu, you can follow these instructions: 1. Add the following line to /et

翟海飞 970

install docker and Nvidia-docker on Ubuntu

install docker and Nvidia-docker on Ubuntu

vernice的专栏 267
上一篇: ubuntu搜狗拼音输入法无法切换英文
下一篇: Oracle 11g 压缩表技术概要
Pierre_
博客等级 码龄19年 2262粉丝 89原创
评论 1
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

Pierre_

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值