I am deploying multiple NestJS microservices to Fly from an nx monorepo. They are each deployed as a separate Fly app and with a separate Fly.toml/Dockerfile. I’d like to place my fly.toml and Dockerfile in the same directories as the subproject apps/microservices. However, my docker build context must run from the root of the monorepo, not inside of the apps/microservices folder.
How can I set the docker build context when doing flyctl deploy?
Example structure (I need to set the docker build context to ./root and do a deploy from 1 of the fly.toml files).
./root apps/ microservice1/ Dockerfile fly.toml // package.json, etc... microservice2/ Dockerfile fly.toml
As a workaround now, I’ve moved fly.toml to the ./root and pointed it to my Dockerfile in the sub directories.