This commit is contained in:
ZhuoQinghui 2024-10-31 14:18:17 +08:00
parent 7e15185359
commit a1defc9aff
4 changed files with 5 additions and 5 deletions

View File

@ -3,7 +3,7 @@ package main
import ( import (
"acme-client/src" "acme-client/src"
"bufio" "bufio"
"github.com/go-acme/lego/v4/log" "log"
"os" "os"
"strings" "strings"
) )

View File

@ -135,7 +135,7 @@ func getCert() {
} }
} }
if !isDoGet { if !isDoGet {
log.Println("日志文件已存在, 无需更新.\n如果需要强制更新, 请使用命令: get -f") fmt.Println("日志文件已存在, 无需更新.\n如果需要强制更新, 请使用命令: get -f")
return return
} }
domainData, err := doGetCert(domain.Name) domainData, err := doGetCert(domain.Name)

View File

@ -1,9 +1,9 @@
package src package src
import ( import (
"github.com/go-acme/lego/v4/log"
"github.com/go-acme/lego/v4/platform/config/env" "github.com/go-acme/lego/v4/platform/config/env"
"gopkg.in/yaml.v3" "gopkg.in/yaml.v3"
"log"
"os" "os"
) )
@ -26,7 +26,7 @@ func InitConfig() {
_, err := os.Stat(confFile) _, err := os.Stat(confFile)
if os.IsNotExist(err) { if os.IsNotExist(err) {
log.Infof("客户端配置文件不存在,自动创建默认配置文件") log.Println("客户端配置文件不存在,自动创建默认配置文件")
conf := defaultConfig() conf := defaultConfig()
file, err := os.Create(confFile) file, err := os.Create(confFile)
if err != nil { if err != nil {

View File

@ -5,7 +5,7 @@ import (
"crypto/rand" "crypto/rand"
"encoding/base64" "encoding/base64"
"encoding/hex" "encoding/hex"
"github.com/go-acme/lego/v4/log" "log"
"math/big" "math/big"
) )