New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🤔 Ability to use tls through autocert? #200
Comments
According to use inside FastHttp, I believe that you can be based on e.g. below: I saw these two examples: |
Tnx, I'll see tomorrow morning |
Hi @Terisback package main
import (
"crypto/tls"
"github.com/gofiber/fiber"
)
func main() {
app := fiber.New()
app.Get("/", func(c *fiber.Ctx) {
c.Send(c.Protocol()) // => https
})
cer, err := tls.LoadX509KeyPair("certs/ssl.cert", "certs/ssl.key")
if err != nil {
log.Fatal(err)
}
config := &tls.Config{Certificates: []tls.Certificate{cer}}
// Start server with https/ssl enabled
app.Listen(443, config)
} |
Closed
Can I please ask if this is still a valid way to use a custom |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Question description
I do not have certificate files, but have Let's Encrypt
What I need to host on https with tls?
The text was updated successfully, but these errors were encountered: