AhHui bu gisti düzenledi 2 months ago. Düzenlemeye git
1 file changed, 2 insertions
.env(dosya oluşturuldu)
| @@ -0,0 +1,2 @@ | |||
| 1 | + | NEXT_PUBLIC_UNSPLASH_API_KEY=your_unsplash_api_key | |
| 2 | + | NEXT_PUBLIC_GOOGLE_ANALYTICS_ID=your_ga_id | |
AhHui bu gisti düzenledi 2 months ago. Düzenlemeye git
1 file changed, 46 insertions
docker-compose.yml(dosya oluşturuldu)
| @@ -0,0 +1,46 @@ | |||
| 1 | + | # 🖼️ Picprose - 多端带壳预览工具 | |
| 2 | + | # 💬 Code Create Life · 如何得与凉风约,不共尘沙一并来! | |
| 3 | + | # 🌿 —— AhHui · 2025 | |
| 4 | + | ||
| 5 | + | services: | |
| 6 | + | picprose: | |
| 7 | + | # 🏷️ 容器名称 | |
| 8 | + | container_name: picprose | |
| 9 | + | ||
| 10 | + | # 📦 使用的镜像 | |
| 11 | + | image: hausen1012/picprose | |
| 12 | + | ||
| 13 | + | # 🔌 端口映射:宿主机3000 → 容器3000 | |
| 14 | + | ports: | |
| 15 | + | - '3000:3000' | |
| 16 | + | ||
| 17 | + | # 🤫 环境变量文件(存放 API Key) | |
| 18 | + | env_file: | |
| 19 | + | - .env | |
| 20 | + | ||
| 21 | + | # ♻️ 自动重启:除非手动停止 | |
| 22 | + | restart: unless-stopped | |
| 23 | + | ||
| 24 | + | # 🩺 健康检查:确保服务正常运行 | |
| 25 | + | healthcheck: | |
| 26 | + | test: ["CMD-SHELL", "curl -f http://localhost:3000 || exit 1"] | |
| 27 | + | interval: 30s | |
| 28 | + | timeout: 10s | |
| 29 | + | retries: 3 | |
| 30 | + | start_period: 40s # ⏱️ 启动初期不检查 | |
| 31 | + | ||
| 32 | + | # 📜 日志配置:防止单个日志过大 | |
| 33 | + | logging: | |
| 34 | + | driver: json-file | |
| 35 | + | options: | |
| 36 | + | max-size: "10m" | |
| 37 | + | max-file: "3" | |
| 38 | + | ||
| 39 | + | # 🌐 加入自定义网络 | |
| 40 | + | networks: | |
| 41 | + | - picprose-net | |
| 42 | + | ||
| 43 | + | # 🌍 自定义桥接网络,用于容器间通信 | |
| 44 | + | networks: | |
| 45 | + | picprose-net: | |
| 46 | + | driver: bridge | |