Overview

Full name
docker.io/ygqygq2/tengine
Registry
docker.io
Namespace
ygqygq2
Repository
tengine
Cached tags
4
Last synced
07/06/2026, 03:03 PM

Introduction

Tengine 高性能 Web 服务器镜像,淘宝 fork 的 Nginx 增强版,支持动态模块、QPS 统计与 upstream 健康检查,适合作反向代理与静态资源网关。

Details

ygqygq2/tengine 打包阿里巴巴 Tengine,兼容 Nginx 配置语法并扩展 ngx_http_upstream_check_module 等能力。镜像监听 80/443,配置经 volume 挂载 nginx.conf 与站点 conf.d。与官方 nginx 相比偏高并发场景;生产应固定 tag、非 root 运行(若镜像支持)、TLS 证书 volume,并将 access/error log 挂载至日志采集路径。

快速启动

docker run -d --name tengine \
  -p 80:80 \
  -v $(pwd)/nginx.conf:/etc/nginx/nginx.conf:ro \
  docker.io/ygqygq2/tengine:latest

推荐实践

docker run -d --name tengine \
  --restart unless-stopped \
  -p 80:80 -p 443:443 \
  -v /etc/tengine/nginx.conf:/etc/nginx/nginx.conf:ro \
  -v /etc/tengine/conf.d:/etc/nginx/conf.d:ro \
  -v /etc/tengine/certs:/etc/nginx/certs:ro \
  docker.io/ygqygq2/tengine:3.1.0

核心参数说明

  • -p 80:80 / 443:443 — HTTP/HTTPS 入口
  • -v .../nginx.conf — 主配置
  • -v .../conf.d — 虚拟主机与 upstream
  • -v .../certs — TLS 证书
  • --restart unless-stopped — 网关持续在线
  • 固定 tag — 动态模块与主版本绑定

Kubernetes

apiVersion: apps/v1
kind: Deployment
metadata:
  name: tengine
spec:
  replicas: 2
  selector:
    matchLabels:
      app: tengine
  template:
    metadata:
      labels:
        app: tengine
    spec:
      containers:
        - name: tengine
          image: docker.io/ygqygq2/tengine:3.1.0
          ports:
            - containerPort: 80
            - containerPort: 443
          volumeMounts:
            - name: config
              mountPath: /etc/nginx/conf.d
      volumes:
        - name: config
          configMap:
            name: tengine-conf
---
apiVersion: v1
kind: Service
metadata:
  name: tengine
spec:
  selector:
    app: tengine
  ports:
    - port: 80
      targetPort: 80

ConfigMap 管理 conf.d;Ingress 或 LoadBalancer 对外,证书用 Secret 挂载。

Latest tags (20)

View all 4 tags →
TagArchPushed AtSizeDigestSyncWishAction
docker.io/ygqygq2/tengine
:latest
linux/amd64linux/arm64
2024/01/07 11:03148.6 MBsha256:0c1020370c14
docker.io/ygqygq2/tengine
:3.1.0
linux/amd64
2024/01/06 18:57148.6 MBsha256:338a085bcf74
docker.io/ygqygq2/tengine
:2.3.3
linux/amd64
2022/11/10 11:34147.6 MBsha256:f33bd7aa7d42
docker.io/ygqygq2/tengine
:2.3.2
linux/amd64
2020/01/07 15:28134.3 MBsha256:d3964383f660