-
Notifications
You must be signed in to change notification settings - Fork 4
Initial CI support to compile the demo #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Here is the actual CI run: https://github.com/GaloisInc/rust-seL4-sel4cp-demo/actions/runs/5481298393/jobs/9985421029 |
I've only just now finished setting up a first take on CI for coliasgroup/rust-seL4, and we haven't yet decided what CI should look like for these demo repositories. Let's revisit this PR once that has been decided. The code from this demo is developed in coliasgroup/rust-seL4 and then manually copied into this repository (see update.sh) , so that this repository can clearly demonstrate a simple build system. For the meantime, I've added a test for this code in the main repository that runs in CI: coliasgroup/rust-sel4@e5af5f3 |
Right on! If you want help with more complex CI setup, I can ask folks here at Galois who deal with CI for our large code bases like Cryptol and Saw. IMHO it would be cool to add at least docker as a target (not everyone uses nix), and perhaps a couple of the most common operating systems for people who want to install/use rust-sel4 directly (Ubuntu/Debian).
Interesting - does this mean that any changes/addition in the banscii crates should be done in What do you think? |
I consider this demo to have three purposes:
From this perspective, the purpose of any testing and CI in this repository would be to demonstrate or suggest one way to set up testing and CI for a Rust-based sel4cp system.
Yes, definitely. The Nix stuff is really just meant for hacking on and testing the Could you clarify what you mean by adding Docker or other environments as targets? I've hacked up some ideas for GitHub actions-based CI for this demo which doesn't require uploading a Docker image that is specific to this repository to the GitHub Packages Container Registry, and allows us to keep the UID/GID convenience. What do you think of these ideas? main...nspin:rust-seL4-sel4cp-demo:nspin/wip/ci-ideas Also, in response to your suggestion about publishing a Docker image, I've drafted a Docker image which contains dependencies and pre-build artifacts for the https://github.com/coliasgroup/rust-seL4-docker-images
I've been primarily developing the code of this demo in the
Do you mean coverage for the code in the |
Hi @nspin !
I meant building and publishing a dedicated docker image as a part of the CI. If you wanted to go beyond that, you could precompile the SDK for various platforms (like Mac, Linux), but that is probably rather excessive at this point.
Very cool! I opened an MR with some suggestions here. Basically, you keep a base image that doesn't have the UID/GID set up, and publish that image. Users then can quickly(!) locally build an image with the UID/GID overlay, so you keep both the convenience of the permissions, and the prebuild image that is easy to download.
Excellent! I wonder if @TrustworthySystems wouldn't mind adopting such image for convenience? That way you avoid having a separate repo for a single dockerfile.
I meant exactly that. Ideally each component is used in at least one demo that is reproducible and build/run as a part of a CI job. I don't have a strong opinion about where the components should be hosted, but I would really like to avoid the Camkes situation, where you have a plethora of components in various repositories, without any indication whether they work or not, and which versions of various libraries (kernel, camkes tool, etc) they require. And no, writing it in a README is not enough:-) |
@nspin I am looking at your http-server example (very cool btw!). I see you have a nix build script for it - maybe link to it in the crate docs and show that the crate is indeed build and tested in the CI? |
I agree that we should provide whatever we can to shorten the distance to a working project for users of this work, and I think publishing Docker images as part of CI is a good idea. However, I think that the scope of any such published artifacts should be the entire rust-seL4 project, not just this demo. The rust-seL4 project-wide Docker image I've drafted is meant to serve this purpose. That repo's CI could publish images, and projects like the one in this repo could depend on those images. How does that line up with what you have in mind?
Providing re-usable sel4cp components isn't really in scope for the rust-seL4 project at the moment. I definitely think that providing re-usable components would be useful (provided that it's done with proper testing and documentation as you noted!), but, for the moment, we're still working on solidifying more foundational aspects of the project. I think that, until the lower level APIs get more eyes and approval and this project is integrated into the foundation's governance+maintenance domain, it will be tough to find the resources or confidence to provide re-usable components in a robust and responsible way. But I totally hear you. When providing re-usable sel4cp components comes into scope, it will certainly be important to test and document them in a rigorous way, which includes CI with user-visible reporting. |
For posterity's sake: https://github.com/coliasgroup/rust-seL4-sel4cp-http-server-demo |
loader.img