mirror of
https://github.com/httpjamesm/AnonymousOverflow.git
synced 2025-05-16 15:03:01 +00:00
feat: strict ratelimit
This commit is contained in:
parent
076f1387f0
commit
8b46beb1dd
2 changed files with 46 additions and 0 deletions
2
main.go
2
main.go
|
@ -14,7 +14,9 @@ func main() {
|
|||
r.LoadHTMLGlob("templates/*")
|
||||
r.Static("/static", "./public")
|
||||
|
||||
r.Use(gin.Recovery())
|
||||
r.Use(middleware.OptionsMiddleware())
|
||||
r.Use(middleware.Ratelimit())
|
||||
|
||||
r.GET("/robots.txt", func(c *gin.Context) {
|
||||
c.String(200, "User-agent: *\nDisallow: /")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue