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
self-hosted spack, or container spackOS #42082
base: develop
Are you sure you want to change the base?
Conversation
Hi @trws! I noticed that the following package(s) don't yet have maintainers:
Are you interested in adopting any of these package(s)? If so, simply add the following to the package class: maintainers("trws") If not, could you contact the developers of this package and see if they are interested? You can quickly see who has worked on a package with $ spack blame gmp Thank you for your help! Please don't add maintainers without their consent. You don't have to be a Spack expert or package developer in order to be a "maintainer," it just gives us a list of users willing to review PRs or debug issues relating to this package. A package can have multiple maintainers; just add a list of GitHub handles of anyone who wants to volunteer. |
Few comments:
|
bootstraps/Makefile defines the full bootstrap in terms of the environments in the four subdirectories, after converting to requirements, this is greatly cleaned up and almost entirely declarative now. The remaining issues being having to enforce the glibc hash in stages 3 and 4, and relying on only the spack built gcc being exactly version 13.2.0 and the host offering at least one lower-version gcc.
This is getting much closer, full bootstrap works again, stage numbers line up, depfile all the way through, much cleaner.
…working compiler that needs path tweaks to work, fails to build runtimes because of path issues
Co-authored-by: Harmen Stoppels <harmenstoppels@gmail.com>
Co-authored-by: Harmen Stoppels <harmenstoppels@gmail.com>
Quick update here: I've had to focus on other things for the past while, I'm going to try to get this rebased today and at least basically straightened out. My understanding of the main thing that needs to happen before the overall thing can be merged is that it needs to build, at least the final stage, in CI. This should require:
I'm not entirely sure how to get the image into our container registry, so that's a bit of a blocker, but I'll see what I can do. |
Thanks. I was waiting for it: #39712 |
This is a big, messy, WIP PR right now but collects all the changes I made to get spack to bootstrap a toolchain from glibc to a fully functional gcc, python and spack environment that can be relocated independently of the base system. An example container for x86_64 containing nothing but spack-built software in a spack root at /spack (and a couple of text files and symlinks) that is also a working bootstrapped spack installation and userland can be found at "trws/spackos-experimental:spackos" on dockerhub. For aarch64 use trws/spackos-experimental:spackos-aarch64
Things that work surprisingly well:
/bin/sh
and/usr/bin/env
from the spack env at/spack/base
and adding super-basicpasswd
andshadow
files, the base system in the container pretty much just works. Bash, coreutils, basically everything you would expect, and despite spack bootstrap claiming it doesn't have clingo on first entry, a "spack bootstrap now" cleans that up without actually installing anything. 🤷Things that definitely need work:
bootstraps/stage{1-4}
in sequence and build them with the following caveats. To make a "spackos" container, delete the.git/*
line from the.dockerignore
file, then use the dockerfile in the bootstraps folder with this command from the spack root:docker buildx build -t spackos-experimental --load -f bootstraps/Dockerfile --target=spackos .
bwrap --dev-bind / / --tmpfs /usr/local --tmpfs /usr/include/x86_64-linux-gnu spack install -v python
-isystem
, C++ compilation will fail because the glibc headers will be moved before the libstdc++ ones. The current workaround for that is really nasty.