You do not need to have the Tryton Dockerfile on github for that because you should not create a new image from scratch to add your modules but you should extend the published image tryton/tryton:5.0.
Here is an example of Dockerfile we use for custom project (one repository with all the custom code):
FROM tryton/tryton:5.0 as builder
RUN mkdir /module
COPY . /module
RUN python3 setup.py sdist
COPY --from=builder /module/dist /dist
RUN pip3 install /dist/* \
&& rm -rf /root/.cache
The file is stored at the top of the repository and you just run
docker build ..
It will still be rejected because installing a module should be done with
setuptools in order to check the dependencies.