Git server side hooks specific to repo

I’m trying to add git server side hooks for a particular repo ( I can’t use global hooks because they differ repo by repo) I checked the the documentation but it seems outdated. Gitaly stores the repo a series of hashed dirs and i don’t know where to put my hooks.
Thank for the help

I just found out about webhooks, they probably are the recomened solution to trigger a ci build; I leave the question open just in case…