Proposal to integrate HyTeG Images to "overhauled CI Environments System"
The reworked CI Image generation is based from a waLBerla centric view. A generalization for this system was discussed in !2. This makes only sense if the HyTeG CI requires a diverse set of CI images.
The following section does not demand a certain realization or generalization for environment generation, but simply imports open ideas from the discussion in !2.
<details>
<summary>Click to expand suggestions</summary>
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43080): (+2 comments)
> Is there a reason why you decided to commit all the environment files now instead of running the generator in the CI? When doing so, we should add a requirements file.
> I assume to ease the extraction of metadata? Which is a nice thought that I approve. But I would suggest putting them into subfolders within `spack-environments/` to improve the overview.
> I'll create a code suggestion to respective files.
>
> I would also recommend reusing the python generation script for all frameworks. Unless the HyTeG team wants to rely on a completely different set of compilers, this is their script would be exactly the same except their `output envs` and `base-yaml` files are called `hyteg` instead of `walberla`.
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43081):
> ```suggestion:-0+0
> OUTPUT_DIR.mkdir(exist_ok=True, parents=True)
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43082):
> ```suggestion:-0+0
> OUTPUT_DIR = SCRIPT_DIR / "spack-environments"
> FRAMEWORK_OUTPUT_DIR = OUTPUT_DIR / FRAMEWORK
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43083):
> I would suggest adding an argument parser here with one required argument. Either `--hyteg` or `--walberla`. To define
> `FRAMEWORK = framework`
>
> Or something like this.
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43084):
> ```suggestion:-0+0
> for f in OUTPUT_DIR.rglob(f"{FRAMEWORK}-*.yaml"):
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43085):
> ```suggestion:-0+0
> env_file = FRAMEWORK_OUTPUT_DIR / f"{env_id}.yaml"
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43086):
> ```suggestion:-0+0
> ci_config_fp = OUTPUT_DIR / f"ci-{FRAMEWORK}.yaml"
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43087):
> ```suggestion:-0+0
> env_id = f"{FRAMEWORK}-{env_id}"
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43088):
> ```suggestion:-0+0
> ENV_BASE_FILE = SCRIPT_DIR / "{FRAMEWORK}-env-base.yaml"
> ```
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43089):
> I'm not sure how inheritance in GitLab CI works.
> I assume the inheritance target was added to the end, since the variables are resolved in order with only one parsing step.
>
> I.e., defining the `SPACK_BASE_IMAGE_URL` as `${REPOSITORY_URL}/spack-stable-${PROVIDER}-base` and choosing defining all providers in the `base-images/ci.yaml` will not work?
- [ ] @ab04unyc started a [discussion](https://i10git.cs.fau.de/ci/images/-/merge_requests/2#note_43090):
> requirements.txt
> ```
> pyyaml
> ```
</details>
task