From 632069216d71d0c0903dbda9032eae9814e87dd6 Mon Sep 17 00:00:00 2001 From: wonder Date: Fri, 26 Jun 2026 00:05:32 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=8D=87=E7=BA=A7=20Go=20=E7=89=88?= =?UTF-8?q?=E6=9C=AC=E8=87=B3=201.24=EF=BC=8C=E4=BF=AE=E5=A4=8D=20.env=20?= =?UTF-8?q?=E7=89=B9=E6=AE=8A=E5=AD=97=E7=AC=A6=E8=BD=AC=E4=B9=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.example | 3 ++- Dockerfile | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index 30322fb..bf68aee 100644 --- a/.env.example +++ b/.env.example @@ -9,4 +9,5 @@ PORT=:8082 # MySQL 连接串(可选,留空则不记录 prompt) # 格式: user:password@tcp(host:port)/dbname?parseTime=true -MYSQL_DSN= +# 注意:如果密码包含特殊字符(如 @、括号等),需要用双引号包围整个 DSN +MYSQL_DSN="user:password@tcp(host:port)/dbname?parseTime=true" diff --git a/Dockerfile b/Dockerfile index 26001a5..ac703b8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.22-alpine AS builder +FROM golang:1.24-alpine AS builder # 使用国内镜像源加速 apk RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories