open-quantum-safe / liboqs-go

Go bindings for liboqs
https://openquantumsafe.org/
MIT License
69 stars 24 forks source link

Add dockerfile for liboqs-go #14

Closed JannisFengler closed 1 year ago

JannisFengler commented 1 year ago

This is a multistage dockerfile which builds liboqs in a build container and then exports the build artifacts to a second container to keep the image as small as possible. After that, it installs liboqs-go and makes it available for Go modules.

JannisFengler commented 1 year ago

I made a new sub directory and added a little documentation :)

JannisFengler commented 1 year ago

It would be great if this container is hosted at docker hub. I changed the Dockerfile so that it builds the tests per default instead of the kem example. As next step, I will add the .circleci file.

baentsch commented 1 year ago

@JannisFengler The image is now accessible at https://hub.docker.com/repository/docker/openquantumsafe/go. Would you agree that now an update (simplification) to https://github.com/open-quantum-safe/liboqs-go#quick-and-dirty-execution-of-examples-with-disposable-docker-containers is sensible? If so, would you want to do another PR for that in the README (and possibly add yourself as a contributor there) or shall we add some suitable language?

JannisFengler commented 1 year ago

I will update the readme in another PR. Maybe it also makes sense to update the use of the docker container so it mounts the directory of the user.

baentsch commented 1 year ago

Maybe it also makes sense to update the use of the docker container so it mounts the directory of the user.

Quite possibly. My approach for the docker README is to consider people only reading the documentation at docker hub and not being versed in PQC. That then gives me contents for a self-contained README that is simply copied as-is to docker-hub. For now I put links at docker hub as I (currently) think that both, docker and project, READMEs are required to understand the contents of the docker image.