fix deprecated function

Signed-off-by: andrewmatilde <davis6813585853062@outlook.com>
This commit is contained in:
andrewmatilde 2023-02-08 10:50:30 +08:00
parent f70a0f5e43
commit 5bafaf3a62
1 changed files with 2 additions and 2 deletions

View File

@ -16,8 +16,8 @@ package httpserver
import (
"crypto/tls"
"crypto/x509"
"io/ioutil"
"net/http"
"os"
"time"
"github.com/gin-gonic/gin"
@ -60,7 +60,7 @@ func (s *HttpServer) startHttpsServer() (err error) {
if mode == MTLSServer {
log.Info("starting HTTPS server with Client Auth", zap.String("address", httpsServerAddr))
caCert, ioErr := ioutil.ReadFile(s.conf.SSLClientCAFile)
caCert, ioErr := os.ReadFile(s.conf.SSLClientCAFile)
if ioErr != nil {
err = ioErr
return