add next-terminal

This commit is contained in:
2025-12-20 08:41:01 +08:00
parent e3ab1a20c7
commit e149fba24f
2 changed files with 75 additions and 0 deletions

43
next-terminal/config.yaml Normal file
View File

@@ -0,0 +1,43 @@
Database:
Enabled: true
Type: postgres
Postgres:
Hostname: postgresql
Port: 5432
Username: next-terminal
Password: 6j3q0hbku7e5
Database: next-terminal
ShowSql: false
log:
Level: debug # 日志等级 debug,info,waring,error
Filename: ./logs/nt.log
Server:
Addr: "0.0.0.0:8088"
App:
Website:
AccessLog: "./logs/access.log" # web 资产的访问日志路径
Recording:
Type: "local" # 录屏文件存储位置,可选 local, s3
Path: "/usr/local/next-terminal/data/recordings"
Guacd:
Drive: "/usr/local/next-terminal/data/drive"
Hosts:
- Hostname: guacd
Port: 4822
Weight: 1
# 反向代理配置,详情参考 https://docs.next-terminal.typesafe.cn/install/config-desc.html
ReverseProxy:
Enabled: false # 是否启用反向代理
HttpEnabled: true # 是否启用 http 反向代理
HttpAddr: ":80" # http 监听地址
HttpRedirectToHttps: false # 是否强制 http 访问转为 https
HttpsEnabled: true # 是否启用 https 反向代理
HttpsAddr: ":443" # https 监听地址
SelfProxyEnabled: true # 是否启用自代理
SelfDomain: "nt.yourdomain.com" # 自代理域名SelfProxyEnabled 为 true 时生效
Root: "" # 系统根路径SelfProxyEnabled 为 flase 时生效。示例https://nt.yourdomain.com
IpExtractor: "direct" # ip 提取方式,可选 direct, x-forwarded-for, x-real-ip
IpTrustList: # 信任的IP地址列表
- "0.0.0.0/0"

View File

@@ -0,0 +1,32 @@
services:
guacd:
container_name: guacd
image: registry.cn-beijing.aliyuncs.com/dushixiang/guacd:latest
volumes:
- ./data:/usr/local/next-terminal/data
restart: always
postgresql:
container_name: postgresql
image: registry.cn-beijing.aliyuncs.com/dushixiang/postgres:16.4
environment:
POSTGRES_DB: next-terminal
POSTGRES_USER: next-terminal
POSTGRES_PASSWORD: next-terminal
volumes:
- ./data/postgresql:/var/lib/postgresql/data
restart: always
next-terminal:
container_name: next-terminal
image: registry.cn-beijing.aliyuncs.com/dushixiang/next-terminal:latest
ports:
- "8088:8088" # Web管理界面
- "2022:2022" # SSH Server 端口 (可选)
volumes:
- /etc/localtime:/etc/localtime:ro
- ./data:/usr/local/next-terminal/data
- ./logs:/usr/local/next-terminal/logs
- ./config.yaml:/etc/next-terminal/config.yaml
depends_on:
- postgresql
- guacd
restart: always