找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
广告投放联系QQ68610888
查看: 50170|回复: 361

[N1盒子] armbian 安装docker 简明教程

 火... [复制链接]
本帖最后由 Randell 于 2020-10-7 21:28 编辑

教程演示使用的armbian为Armbian-5.77 on N1, so far so good
#第一步 换源
  1. nano /etc/apt/sources.list
复制代码
直接删除或者#注释掉原有的源
复制粘贴下面的源
  1. deb http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic main multiverse restricted universe
  2. deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic main multiverse restricted universe
  3. deb http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-backports main multiverse restricted universe
  4. deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-backports main multiverse restricted universe
  5. deb http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-proposed main multiverse restricted universe
  6. deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-proposed main multiverse restricted universe
  7. deb http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-security main multiverse restricted universe
  8. deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-security main multiverse restricted universe
  9. deb http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-updates main multiverse restricted universe
  10. deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ bionic-updates main multiverse restricted universe
复制代码
ctrl+x退出编辑,按y回车保存,执行
  1. apt-get update
  2. apt-get upgrade
复制代码

#第二步 安装Docker
输入如下命令:
  1. curl -fsSL https://get.docker.com -o get-docker.sh
  2. sh get-docker.sh --mirror Aliyun
复制代码
调用了阿里云加速安装。如果失败可以尝试重启一下机器,再次运行脚本。
#第三步 Docker换源
  1. nano /etc/docker/daemon.json
复制代码
复制粘贴如下
  1. {
  2. "registry-mirrors": [
  3. "https://kfwkfulq.mirror.aliyuncs.com",
  4. "https://2lqq34jg.mirror.aliyuncs.com",
  5. "https://pee6w651.mirror.aliyuncs.com",
  6. "https://registry.docker-cn.com",
  7. "http://hub-mirror.c.163.com"
  8. ],
  9. "dns": ["8.8.8.8","8.8.4.4"]
  10. }
复制代码
ctrl+x退出编辑,按y回车保存,执行
  1. systemctl daemon-reload
  2. systemctl restart docker
复制代码
#第四步 安装面板
  1. docker pull portainer/portainer:linux-arm64
  2. docker volume create portainer_data
  3. docker run -d -p 9000:9000 --name portainer -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer:linux-arm64
复制代码
结束。没啥好说的。觉得不错,甜糖可以填写我的邀请码:660003.

一些命令:
  1. #重启docker
  2. systemctl daemon-reload
  3. systemctl restart docker

  4. #查看docker是否运行成功
  5. ps -ef |grep docker

  6. #docker查看本地镜像
  7. docker image ls
复制代码
更新:
如何更新容器
举例:Portainer更新
1.停止旧的容器
  1. docker stop portainer
复制代码
2.删除旧的容器
  1. docker rm portainer
复制代码
3.删除旧的镜像
  1. docker rmi portainer/portainer
复制代码
4.拉取新的镜像,注意portainer从2.0.0版本镜像名字改为portainer/portainer-ce
  1. docker pull portainer/portainer-ce
复制代码
5.使用新的镜像启动新的容器
  1. docker run -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock --restart=always --name portainer portainer/portainer-ce
复制代码


参考:Docker 配置国内阿里云镜像源
N1 刷入 Armbian 5.77 安装 Docker OpenWRT 等
Portainer更新方法












评分

参与人数 2恩山币 +2 收起 理由
voo*** + 1 一看就是觉得高端、大气、上档次!
iii*** + 1 感谢你的分享,无论怎样,你都是最无私的人!来,说说,你E盘上还有啥一起给我吧!

查看全部评分

我的恩山、我的无线 The best wifi forum is right here.
来自手机 | 显示全部楼层
这个是啥东西
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

回复看见隐藏
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

来自手机 | 显示全部楼层
又是甜糖?
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

路过,学习一下!
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

666666666666
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

安装docker 简明教程
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

学习学习
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

谢谢分享。。。
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

学习学习
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

来自手机 | 显示全部楼层
armbian-config安装更简明!
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

RE: armbian 安装docker 简明教程 [修改]
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

是用网页来管理么?
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

学习一下学习一下
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

6666666666
我的恩山、我的无线 The best wifi forum is right here.
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关闭

欢迎大家光临恩山无线论坛上一条 /1 下一条

有疑问请添加管理员QQ86788181|手机版|小黑屋|Archiver|恩山无线论坛(常州市恩山计算机开发有限公司版权所有) ( 苏ICP备05084872号 )

GMT+8, 2024-4-29 16:07

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

| 江苏省互联网有害信息举报中心 举报信箱:js12377 | @jischina.com.cn 举报电话:025-88802724 本站不良内容举报信箱:68610888@qq.com 举报电话:0519-86695797

快速回复 返回顶部 返回列表