[docs] Add custom Kubernetes manifest API documentation#927
Open
aspire-repo-bot[bot] wants to merge 1 commit into
Open
[docs] Add custom Kubernetes manifest API documentation#927aspire-repo-bot[bot] wants to merge 1 commit into
aspire-repo-bot[bot] wants to merge 1 commit into
Conversation
Documents the new AddManifest API added in microsoft/aspire#16883, including polyglot examples (TypeScript, Python, Java, Go) and a configuration reference table. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
14 tasks
Contributor
There was a problem hiding this comment.
Pull request overview
Adds documentation for custom Kubernetes manifest support in the Kubernetes integration page, covering polyglot AppHost usage and C# guidance.
Changes:
- Added an “Add custom Kubernetes manifests” section.
- Added multi-language examples for attaching KEDA-style manifests.
- Added a manifest configuration method reference table and C# note.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| `AddManifest` takes the manifest's `apiVersion`, `kind`, and `metadata.name`, and returns a handle that you can use to set labels, annotations, a namespace, and arbitrary field values using dot-notation paths. | ||
|
|
||
| <Tabs syncKey='aspire-lang'> |
| builder.AddContainer("service", "nginx") | ||
| .PublishAsKubernetesService(resource => | ||
| { | ||
| var scaler = new ScaledObject |
Comment on lines
+259
to
+262
| | `WithNamespace(string)` / `with_namespace` | Sets the Kubernetes namespace for the manifest. | | ||
| | `WithLabel(key, value)` / `with_label` | Adds a metadata label to the manifest. | | ||
| | `WithAnnotation(key, value)` / `with_annotation` | Adds a metadata annotation to the manifest. | | ||
| | `WithField(path, value)` / `with_field` | Sets an arbitrary field using dot-notation path (for example, `spec.maxReplicaCount`). | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Documents changes from microsoft/aspire#16883 by
@sebastienros.What changed
Aspire 13.4 adds
AddManifestonKubernetesResource, allowing polyglot AppHost authors (TypeScript, Python, Java, Go) to attach arbitrary Kubernetes manifests — such as KEDAScaledObjectdefinitions — to the generated Helm chart. The C# side continues to useAdditionalResourcesdirectly.Targeting
release/13.4based on the source PR milestone13.4.Why this PR is needed
The Kubernetes integration docs page (
integrations/compute/kubernetes.mdx) had no coverage for this new API surface. Users would have no discoverability forAddManifest/addManifest/add_manifestor the manifest handle configuration methods.Summary of changes
Added a new Add custom Kubernetes manifests section to the Kubernetes integration docs with:
WithNamespace,WithLabel,WithAnnotation,WithField)AddManifestvs.AdditionalResourcesin C#Files modified
src/frontend/src/content/docs/integrations/compute/kubernetes.mdx(updated)