Skip to content

feat(scripts): add project-resource-graph.sh - #18

Open
devpie wants to merge 1 commit into
stackitcloud:mainfrom
devpie:feature/project-resource-graph
Open

feat(scripts): add project-resource-graph.sh#18
devpie wants to merge 1 commit into
stackitcloud:mainfrom
devpie:feature/project-resource-graph

Conversation

@devpie

@devpie devpie commented Sep 7, 2026

Copy link
Copy Markdown

Description

Adds scripts/project-resource-graph.sh. The script lists the resources of one or more STACKIT projects and shows which of them reference each other. It runs the list command of every service in its built-in table in parallel, collects all IDs, and searches each object for strings that equal the ID of another object, so edges do not depend on hard-wired field names. Output as text, Mermaid or JSON.

With --delete KIND/NAME it resolves the selectors against the collected inventory, orders the steps so that referencing objects go first, prints the plan with warnings, and asks for the project ID as confirmation before calling the CLI. Every executed run writes an evidence file into the current directory. image (system catalog) and kms-keyring are never deleted.

Also adds the overview row and a section to scripts/README.md and regenerates AGENTS.md.

Verification: 35 characterization cases against a fake stackit CLI (text, Mermaid and JSON output, key selection, all error paths, the delete path with confirmation on a pseudo-terminal) on bash 3.2 and 5.3; shellcheck reports nothing.

Checklist

  • The CI pipeline passed successfully.

🤖 Generated with Claude Code

Lists the resources of one or more STACKIT projects, derives references
between them from IDs found inside the objects, and optionally deletes
selected objects ordered by those references after an explicit
confirmation. Renders text, Mermaid or JSON.

Adds the overview row and a section to scripts/README.md and regenerates
AGENTS.md.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant