Personal Data Preservation Plan: Installing Docker
Quick Start Install Container Station from App Center Then it's recommended to first create a Container folder yourself in File Station, so you can control which volume Docker data is saved on; I put it on the SSD. After installation, the first time you open it you'll be prompted to create a Container shared folder; just select the Container directory you created earlier. Then it's all back to the command line It comes with docker-compose by default
目录6 个章节
Quick Start
Install Container Station from App Center
Then it's recommended to first create a Container folder yourself in File Station, so you can control which volume Docker data is saved on; I put it on the SSD.
After installation, the first time you open it you'll be prompted to create a Container shared folder; just select the Container directory you created earlier.
Then it's all back to the command line
It comes with docker-compose by default, no extra installation needed.
Or visit GitHub to see what the latest version is https://github.com/docker/compose/releases
I'm not going to bother with that.
Configure Hub Mirror
First find out where Docker is installed
which docker
Output
/share/CACHEDEV1_DATA/.qpkg/container-station/bin/docker
Go to the config file directory
cd /share/CACHEDEV1_DATA/.qpkg/container-station/etc
Edit the config file; this docker.json is equivalent to /etc/docker/daemon.json on a regular Linux system
vim docker.json
Add at the bottom
"registry-mirrors": [
"https://docker.mirrors.ustc.edu.cn"
]
Or your own Alibaba Cloud acceleration mirror works too
Then restart Docker
sudo /etc/init.d/container-station.sh restart
Install Portainer
A graphical interface, convenient for managing Docker
Deploy using docker-compose
Just create /share/Container/softwares/portainer/docker-oompose.yml
version: "3"
services:
portainer:
image: portainer/portainer-ce
restart: unless-stopped
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./portainer_data:/data
ports:
- 9100:9000
Then just start it with docker-compose up
Visit http://nas_ip:9100 to set the username and password, select local for the environment, and you're done
Issues Encountered
Error when installing an image
write /var/lib/docker/tmp/GetImageBlob4256196071: no space left on device
After checking, /var/lib/docker was not linked inside the shared directory /Container
Recreate the link
cd /var/lib
sudo mv docker docker2
sudo ln -s /share/CACHEDEV1_DATA/.qpkg/container-station/var/lib/docker docker
References
- Three methods to change Docker's default storage location: https://blog.csdn.net/BigData_Mining/article/details/104921479
References
- Installing Docker (Container Station) on QNAP NAS - https://zhuanlan.zhihu.com/p/468539826
- How to reproduce and view docker run parameter commands - http://www.linuxea.com/2270.html
- Using Docker elegantly on QNAP - https://haoyu.love/blog1219.html
- https://www.chenyupeng.com/archives/为威联通nas设置dockerhub加速源
_EOF_
Personal Data Preservation Plan: Installing Docker
- 本文作者:
- 程序设计实验室
- 版权声明:
- 本博客所有文章除特别声明外,均采用 BY-NC-SA 许可协议。转载请注明出处!
相关文章
为什么我给虚拟机分了 32G 硬盘,Ubuntu 却只识别 16G?
32G硬盘在PVE里明明分配好了,到Ubuntu就变15G,LVM这鬼东西把空间藏哪儿去了?根目录就分了一半?这算哪门子逻辑,简直离谱。扩容三步走倒是简单,但谁特喵会用到这种坑爹设计。
2025-10-10 · 个人数据保全计划 · 约 1 分钟
PVE折腾笔记 (3) 在原QNAP使用的硬盘上创建ZFS
QNAP硬盘换ZFS?自愈功能挺好用,但折腾Linux兼容性够闹心。LVM残留导致擦盘失败?内核对象得一个个干掉。Pool创建时参数选错?那可真是后患无穷。
2025-06-19 · 个人数据保全计划 · 约 1 分钟
个人数据保全计划:部署joplin server笔记同步服务
在这个数据爆炸的时代,个人数据的价值愈发凸显,成为我们生活与工作中无可替代的重要资产。上一篇文章里,我介绍了从印象笔记迁移至 Joplin 的过程,这是我寻求数据自主掌控的关键一步。在探索同步方案时,我尝试了 OneDrive,原以为它能提供稳定高效的同步服务,可实际使用时却发现它对小文件缺乏优化,同步速度极慢,极大影响了使用体验。虽说目前还不确定是否存在数据丢失问题,但这样的效率实在难以满足我的
2025-02-02 · 个人数据保全计划 · 约 1 分钟
个人数据保全计划:(3)RAID与存储方案
iNode越小,可用空间也越小
2022-11-04 · 个人数据保全计划 · 约 1 分钟
讨论
共 0 条加载评论中…