docker run --rm --mount type=bind,src=`pwd`,dst=/data pyshacl -s /data/shacl.ttl /data/ontology.ttl
test and benchmark need to exist or the build fails even with poetry install --no-dev so they can't be put into .dockerignore
I didn't specify versions for poetry and only major version 3 for python but no version after the dot to reduce the update burden but you may want to use constrain dependency versions instead. However that seems to be the same workflow as a developer would use, as in install the latest poetry and the latest python.
all other dependencies should follow the normal rules, as specified in poetry.lock
Tested locally as
docker build . -t pyshacl
and thencd
into a copy of https://github.com/hitontology/ontology/ and then:poetry install --no-dev
so they can't be put into .dockerignore