# ContainerResource.WithContainerCertificatePaths

- Module: [Aspire.Hosting](/reference/api/go/aspire.hosting.md)
- Defined on: [ContainerResource](/reference/api/go/aspire.hosting/containerresource.md)
- Version: `17.0.0`
- Kind: `method`

Adds container certificate path overrides used for certificate trust at run time.

## Definition

```go
type ContainerResource interface {
    // ... omitted for brevity
    WithContainerCertificatePaths(options ...*WithContainerCertificatePathsOptions) ContainerResource
}
```

## Signature

```go
WithContainerCertificatePaths(options ...*WithContainerCertificatePathsOptions) ContainerResource
```

## Parameters

- `options` (`...*WithContainerCertificatePathsOptions`) -- optional settings, see [Options](#options)

## Options

Optional parameters are passed in a trailing `options ...*WithContainerCertificatePathsOptions` argument.

- `CustomCertificatesDestination` (`*string`) -- The destination path in the container where custom certificates will be copied.
- `DefaultCertificateBundlePaths` (`[]string`) -- Default certificate bundle paths in the container that will be replaced.
- `DefaultCertificateDirectoryPaths` (`[]string`) -- Default certificate directory paths in the container that may be appended.

## Returns

[`ContainerResource`](/reference/api/go/aspire.hosting/containerresource.md) -- The updated resource builder.

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

## Defined on

- [ContainerResource](/reference/api/go/aspire.hosting/containerresource.md) -- `handle`
