# DuckDBResource

- Module: [CommunityToolkit.Aspire.Hosting.DuckDB](/reference/api/go/communitytoolkit.aspire.hosting.duckdb.md)
- Version: `13.6.1`
- Kind: `handle`
- Source: [GitHub](https://github.com/CommunityToolkit/Aspire/tree/d9c2addac6f527ef2e33712d290b84574b455a3b)

## Definition

```go
type DuckDBResource interface {
    ExpressionValue
    Resource
    ResourceWithConnectionString
}
```

## Embeds

- `ExpressionValue`
- `Resource`
- `ResourceWithConnectionString`

## Methods

- [WithReadOnly](/reference/api/go/communitytoolkit.aspire.hosting.duckdb/duckdbresource/withreadonly.md) -- `method` -- Configures the DuckDB resource to open the database in read-only mode.
  ```go
  WithReadOnly() DuckDBResource
  ```
