折腾docker留下的配置文件

621 字
3 分钟
折腾docker留下的配置文件

docker-compose.yaml#

一些docker-compose.yaml配置文件

immich-app#

immich-app:相册管理软件

docker-compose.yaml

name: immich
services:
immich-server:
container_name: immich_server
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/ghcr.io/immich-app/immich-server:v2.5.6
volumes:
- ${UPLOAD_LOCATION}:/data
- /etc/localtime:/etc/localtime:ro
env_file:
- .env
ports:
- '2283:2283'
depends_on:
- redis
- database
restart: always
healthcheck:
disable: false
immich-machine-learning:
container_name: immich_machine_learning
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/ghcr.io/immich-app/immich-machine-learning:v1.138.0
volumes:
- ${MODEL_LOCATION}:/cache
env_file:
- .env
restart: always
healthcheck:
disable: false
redis:
container_name: immich_redis
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/valkey/valkey:8-bookworm
healthcheck:
test: redis-cli ping || exit 1
restart: always
database:
container_name: immich_postgres
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/ghcr.io/immich-app/postgres:14-vectorchord0.4.3-pgvectors0.2.0
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_DB: ${DB_DATABASE_NAME}
POSTGRES_INITDB_ARGS: '--data-checksums'
volumes:
- ${DB_DATA_LOCATION}:/var/lib/postgresql/data
shm_size: 128mb
restart: always

配套的.env文件

# 上传照片的位置
UPLOAD_LOCATION=./library
# 数据库位置
DB_DATA_LOCATION=./postgres
IMMICH_VERSION=release
# 数据库配置
DB_PASSWORD=你的数据库密码
DB_USERNAME=你的数据库账户名
DB_DATABASE_NAME=immich
# 机器学习的模型位置
MODEL_LOCATION=./model
HF_ENDPOINT=https://hf-mirror.com
HF_MIRROR=asia

minIO#

OSS对象存储

docker-compose.yaml

services:
minio:
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/minio/minio:RELEASE.2025-04-22T22-12-26Z
container_name: minio
restart: unless-stopped
ports:
- "19000:9000"
- "19001:9001"
environment:
MINIO_ROOT_USER: ${MINIO_ROOT_USER}
MINIO_ROOT_PASSWORD: ${MINIO_ROOT_PASSWORD}
volumes:
- ./data:/data
command: server /data --console-address ":9001"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 10s
retries: 3

配套的.env文件

MINIO_ROOT_USER=<你的用户名>
MINIO_ROOT_PASSWORD=<你的密码>

synapse#

即时IM工具

docker-compose.yaml

services:
# 生成 Synapse 配置文件
synapse-generate:
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/matrixdotorg/synapse:v1.149.1
container_name: synapse-generate
volumes:
- ./data:/data
environment:
- SYNAPSE_SERVER_NAME=kulve.com
- SYNAPSE_REPORT_STATS=no
command: generate
restart: no
# 启动 Synapse 服务
synapse:
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/matrixdotorg/synapse:v1.149.1
container_name: synapse
volumes:
- ./data:/data
ports:
- "8008:8008"
- "8009:8009"
- "8448:8448"
restart: unless-stopped
depends_on:
- synapse-generate

./data/homeserver.yaml

# Configuration file for Synapse.
#
# This is a YAML file: see [1] for a quick introduction. Note in particular
# that *indentation is important*: all the elements of a list or dictionary
# should have the same indentation.
#
# [1] https://docs.ansible.com/ansible/latest/reference_appendices/YAMLSyntax.html
#
# For more information on how to configure Synapse, including a complete accounting of
# each option, go to docs/usage/configuration/config_documentation.md or
# https://element-hq.github.io/synapse/latest/usage/configuration/config_documentation.html
server_name: "kulve.com"
pid_file: /data/homeserver.pid
listeners:
- port: 8008
resources:
- compress: false
names:
- client
- federation
tls: false
type: http
x_forwarded: true
database:
name: sqlite3
args:
database: /data/homeserver.db
log_config: "/data/kulve.com.log.config"
media_store_path: /data/media_store
registration_shared_secret: "你的注册共享密钥"
report_stats: false
macaroon_secret_key: "密钥"
form_secret: "密钥"
signing_key_path: "/data/kulve.com.signing.key"
trusted_key_servers:
- server_name: "matrix.org"
presence:
enabled: true
max_avatar_size: 10M #最大头像上传大小
allow_profile_lookup_over_federation: false
max_upload_size: 1024M #最大文件上传大小
enable_registration: true #是否启用注册
enable_registration_without_verification: true
registrations_require_3pid: [] #允许的3pid注册方式
allow_guest_access: false #禁止访客
user_directory:
enabled: true
search_all_users: true
prefer_local_users: true
show_locked_users: false
#log_config: "/data/synapse.log.config"

searXNG#

自建搜索引擎,已停止使用

docker-compose.yaml

services:
redis:
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/valkey/valkey:9-alpine
container_name: searxng-redis
restart: unless-stopped
command: valkey-server --save 30 1 --loglevel warning
networks:
- searxng-network
volumes:
- ./data/redis:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 30s
timeout: 10s
retries: 3
searxng:
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/searxng/searxng:2026.5.21-b9340f50c
container_name: searxng
restart: unless-stopped
depends_on:
redis:
condition: service_healthy
networks:
- searxng-network
ports:
- "8002:8080"
volumes:
- ./settings.yaml:/etc/searxng/settings.yml:ro
- ./data/searxng:/var/cache/searxng
environment:
- SEARXNG_BASE_URL=http://81.70.245.32:8002/
- INSTANCE_NAME=my-searxng-api
networks:
searxng-network:
driver: bridge

配套的settings.yaml文件

use_default_settings: true
general:
instance_name: "SearXNG API"
search:
safe_search: 0
formats:
- html
- json
results_per_page: 10
server:
secret_key: "你自己的key"
limiter: false # 关闭限速
image_proxy: false
bind_address: "0.0.0.0"
port: 8080
ui:
default_theme: simple
engines:
- name: bing
disabled: false
- name: baidu
disabled: false
- name: sogou
disabled: false
- name: 360search
disabled: false
- name: bilibili
disabled: false
outgoing:
request_timeout: 10.0
max_request_timeout: 15.0
useragent_suffix: ""
pool_connections: 20
pool_maxsize: 5

支持与分享

如果这篇文章对你有帮助,欢迎分享给更多人或赞助支持!

赞助
折腾docker留下的配置文件
https://kulve.tech/posts/docker-compose配置文件/
作者
Kulve
发布于
2026-06-06
许可协议
CC BY-NC-SA 4.0
Profile Image of the Author
Kulve
Hello, I'm Kulve.
公告
欢迎来到我的博客!这是一则示例公告。正在建设与测试此网站。
音乐
封面

音乐

暂未播放

0:00 0:00
暂无歌词
分类
标签
站点统计
文章
6
分类
5
标签
14
总字数
3,956
运行时长
0
最后活动
0 天前

文章目录