mirror of
https://github.com/mochi-mqtt/server.git
synced 2025-10-22 07:40:18 +08:00
feat: Add TLS Cert File flag (#434)
Co-authored-by: JB <28275108+mochi-co@users.noreply.github.com>
This commit is contained in:
@@ -57,7 +57,10 @@ func main() {
|
||||
done <- true
|
||||
}()
|
||||
|
||||
cert, err := tls.X509KeyPair(testCertificate, testPrivateKey)
|
||||
// Load tls cert from your cert file
|
||||
cert, err := tls.LoadX509KeyPair("replace_your_cert.pem", "replace_your_cert.key")
|
||||
|
||||
//cert, err := tls.X509KeyPair(testCertificate, testPrivateKey)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user