How to install native dependency when using Auto DevOps?

My project is a Ruby application that is tested and deployed with Auto DevOps.

During the test and in the production environment, the application needs to have OpenJDK 11 and Graphviz installed.

Currently, I solved this by specifying my own Dockerfile. It mostly works, but I need to duplicate a lot of work that Auto DevOps could handle for me, and the container is not quite what Auto DevOps expects, causing it to rebuild Ruby from source, which was not the case without a Dockerfile.