# WithExtraArg

- Module: [CommunityToolkit.Aspire.Hosting.K3s](/reference/api/go/communitytoolkit.aspire.hosting.k3s.md)
- Version: `13.6.1`
- Kind: `method`
- Defined on: [`K3sClusterResource`](/reference/api/go/communitytoolkit.aspire.hosting.k3s/k3sclusterresource.md)
- Source: [GitHub](https://github.com/CommunityToolkit/Aspire/tree/d9c2addac6f527ef2e33712d290b84574b455a3b)

Appends a raw argument to the `k3s server` command line.

## Remarks

Use `WithDisabledComponent` or the dedicated CIDR methods when possible.
This method is intended for flags that have no dedicated helper.

## Definition

```go
func (K3sClusterResource) WithExtraArg(arg string) K3sClusterResource
```

## Parameters

- `arg` (`string`) -- The raw argument to append, e.g. `--write-kubeconfig-mode=644`. Call this method multiple times to append additional arguments.

## Returns

[`K3sClusterResource`](/reference/api/go/communitytoolkit.aspire.hosting.k3s/k3sclusterresource.md) -- The same builder, for chaining.

Returns a handle; failures surface later via `Err()`.

## Applies to

- [`K3sClusterResource`](/reference/api/go/communitytoolkit.aspire.hosting.k3s/k3sclusterresource.md)
