From 59af67a5b546e5ee79c3d0b56eccf92403627ea0 Mon Sep 17 00:00:00 2001 From: sagit Date: Fri, 6 Feb 2026 07:11:05 +0000 Subject: [PATCH] chore: migrate compose images to ghcr and reduce log output --- docker-compose-v4.yml | 14 +++++++++++--- docker-compose-v6.yml | 14 +++++++++++--- install.sh | 6 ++++-- 3 files changed, 26 insertions(+), 8 deletions(-) diff --git a/docker-compose-v4.yml b/docker-compose-v4.yml index 22067ab..81fff43 100644 --- a/docker-compose-v4.yml +++ b/docker-compose-v4.yml @@ -1,8 +1,12 @@ services: backend: - image: bqlpfy/springboot-backend:2.0.7-beta + image: ghcr.io/sagit-chu/springboot-backend:2.0.7-beta container_name: springboot-backend restart: unless-stopped + logging: + driver: json-file + options: + max-size: "20m" environment: DB_PATH: /app/data/gost.db JWT_SECRET: ${JWT_SECRET} @@ -25,9 +29,13 @@ services: start_period: 60s frontend: - image: bqlpfy/vite-frontend:2.0.7-beta + image: ghcr.io/sagit-chu/vite-frontend:2.0.7-beta container_name: vite-frontend restart: unless-stopped + logging: + driver: json-file + options: + max-size: "20m" ports: - "${FRONTEND_PORT}:80" depends_on: @@ -52,4 +60,4 @@ networks: driver: bridge ipam: config: - - subnet: 172.20.0.0/16 \ No newline at end of file + - subnet: 172.20.0.0/16 diff --git a/docker-compose-v6.yml b/docker-compose-v6.yml index 0b5156e..8694a25 100644 --- a/docker-compose-v6.yml +++ b/docker-compose-v6.yml @@ -1,8 +1,12 @@ services: backend: - image: bqlpfy/springboot-backend:2.0.7-beta + image: ghcr.io/sagit-chu/springboot-backend:2.0.7-beta container_name: springboot-backend restart: unless-stopped + logging: + driver: json-file + options: + max-size: "20m" environment: DB_PATH: /app/data/gost.db JWT_SECRET: ${JWT_SECRET} @@ -25,9 +29,13 @@ services: start_period: 60s frontend: - image: bqlpfy/vite-frontend:2.0.7-beta + image: ghcr.io/sagit-chu/vite-frontend:2.0.7-beta container_name: vite-frontend restart: unless-stopped + logging: + driver: json-file + options: + max-size: "20m" ports: - "${FRONTEND_PORT}:80" depends_on: @@ -54,4 +62,4 @@ networks: ipam: config: - subnet: 172.20.0.0/16 - - subnet: fd00:dead:beef::/48 \ No newline at end of file + - subnet: fd00:dead:beef::/48 diff --git a/install.sh b/install.sh index 20f368c..8f0cca9 100644 --- a/install.sh +++ b/install.sh @@ -295,6 +295,8 @@ After=network.target WorkingDirectory=$INSTALL_DIR ExecStart=$INSTALL_DIR/flux_agent Restart=on-failure +StandardOutput=null +StandardError=null [Install] WantedBy=multi-user.target @@ -312,8 +314,8 @@ EOF echo "📁 配置目录: $INSTALL_DIR" echo "🔧 服务状态: $(systemctl is-active flux_agent)" else - echo "❌ flux_agent服务启动失败,请执行以下命令查看日志:" - echo "journalctl -u flux_agent -f" + echo "❌ flux_agent服务启动失败,请执行以下命令查看状态:" + echo "systemctl status flux_agent --no-pager" fi }