剪藏#剪藏#爱踢人生sre

docker部署tugtainer系统,实现docker容器应用镜像自动更新

2026 年 4 月 20 日1 分钟
分享Twitter / XTelegram微博
docker部署tugtainer系统,实现docker容器应用镜像自动更新 封面

1、安装docker

1、安装依赖包

yum install -y yum-utils device-mapper-persistent-data lvm2

2、配置docker yum源

yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo

3、安装docker

yum install -y docker-ce

4、修改docker配置文件

mkdir /etc/docker -p

sudo tee /etc/docker/daemon.json <<-'EOF'

{

"registry-mirrors":[

"https://docker.credclouds.com",

"https://k8s.credclouds.com",

"https://quay.credclouds.com",

"https://gcr.credclouds.com",

"https://k8s-gcr.credclouds.com",

"https://ghcr.credclouds.com",

"https://do.nark.eu.org",

"https://docker.m.daocloud.io",

"https://docker.nju.edu.cn",

"https://docker.mirrors.sjtug.sjtu.edu.cn",

"https://docker.1panel.live",

"https://docker.rainbond.cc"

],

"data-root":"/etc/docker"

}

EOF

5、启动docker

systemctl daemon-reload

systemctl enable docker --now

systemctl restart docker

6、安装docker-compose

#下载docker-compose文件

curl -L "https://github.com/docker/compose/releases/download/v2.29.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose

#给他一个执行权限

chmod +x /usr/local/bin/docker-compose

ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose

#查看是否安装成功

docker-compose --version

2、拉取tugtainer镜像

docker pull quenary/tugtainer:latest

3、创建数据目录

mkdir -p /data/tugtainer

chmod 777 /data/tugtainer

4、编辑docker-compose.yaml文件

vi /data/tugtainer/docker-compose.yaml

networks:

tugtainer:

driver:bridge

services:

app:

container_name:tugtainer

image:quenary/tugtainer:latest

volumes:

-/data/tugtainer/data:/tugtainer

-/var/run/docker.sock:/var/run/docker.sock

restart:unless-stopped

networks:

-tugtainer

ports:

-8080:80

5、启动tugtainer容器

cd /data/tugtainer/

docker-compose up -d

docker-compose ps

Notion image

6、查看容器日志

docker logs -f tugtainer

Notion image

7、访问tugtainer服务

浏览器访问: http://192.168.52.15:8080

创建登陆密码:

Notion image

Notion image

Notion image

Notion image

8、tugtainer功能介绍

1.主机

Notion image

2.容器

Notion image

3.镜像

Notion image

4.设置

Notion image

原文地址: https://mp.weixin.qq.com/s?__biz=MzI0MDg2NTc2Ng==&mid=2247534650&idx=1&sn=653ff80ae1bffe467dfe8729331b3123&chksm=e81ea6c5d0e875f4e81264e04f81a821b66338d54e93e594837243cd3e57079892181c024022&mpshare=1&scene=1&srcid=0420Jech8OzF0wOaqB2MtvSo&sharer_shareinfo=6015bf36e609180f576bcfd7eb8208d5&sharer_shareinfo_first=6015bf36e609180f576bcfd7eb8208d5#rd

相关文章