GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

No menu could be recovered. Follow the blue links in the page.

This view

  • Original page
  • New address

GeezerVison is showing gitlab.com — feat(config): resolve fragment file paths against the fragment's directory (!1133) · Merge requests · GitLab.org / caproni · GitLab

feat(config): resolve fragment file paths against the fragment's directory

feat(config): resolve fragment file paths against the fragment's directory
Manuel Schönlaubrequested to merge
ms-fragment-relative-paths into main Nov 19, 2026
  • Overview 3
  • Commits 1
  • Pipelines 1
  • Reports -
  • Changes 9

What does this merge request do and why?

This MR makes file paths declared inside a config fragment resolve against the fragment's own directory instead of the directory holding caproni.yaml.

A fragment is a partial caproni.yaml pulled in through extends:. Fragments can live in subdirectories so they can ship their own supporting files, but until now a values_file: ./values.yaml in services/caproni.valkey.yaml was looked up next to caproni.yaml, not next to the fragment. A fragment therefore could not be moved together with its files, which is the point of putting it in a subdirectory.

The loader now rebases the path fields of a subdirectory fragment onto the config directory on the raw YAML, before the fragment is merged. Whichever layer wins a key already carries a path in the right frame, so ResolvePath and its callers are untouched, and an override in caproni.yaml keeps resolving against the config directory while an override of an unrelated key keeps the fragment's path. Rebased fields are a Helm values_file, a version_map, the sources of an inline_file override, a kustomize path, and the path of a file variable. Workspace locations (repository directory, the repository of a gitlab_repo_version_files override, a skaffold config_file) stay as they were. A fragment next to caproni.yaml is unchanged.

Remote fragments keep their existing per-reference handling; moving them onto the same rewrite is a follow-up.

References

  • Closes #180
  • Supersedes !489 (closed), which threaded a per-element source directory through every consumer

How to set up and validate locally

  1. Create caproni.yaml with extends: [./services/caproni.app.yaml] and a Helm deployer-free base.
  2. In services/caproni.app.yaml, declare a Helm deployer with values_file: ./values.yaml, and put values.yaml next to the fragment.
  3. Run caproni config print and confirm the deployer shows values_file: services/values.yaml.
  4. Override values_file: mine.yaml for that deployer in caproni.yaml and confirm the printed config shows mine.yaml, resolved from the config directory.

🤖 Generated with Claude Code

Merge request reports

Assignee Loading
Reviewers Loading
Request review from
Loading
Time tracking Loading
Loading
Loading
Loading
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.