# with_cpu_limit

Set CPU limit for the container.

```rhai
container.with_cpu_limit(cpus) -> Container
```

## Parameters

- `cpus` (string): CPU limit (e.g., "1.5", "2")

## Returns

Returns the `Container` builder for method chaining.

## Examples

```rhai
// Limit to 1.5 CPUs
let container = nerdctl_container_from_image("app", "myapp:latest")
    .with_cpu_limit("1.5")
    .with_memory_limit("512m")
    .build();
```

## Notes

- This is a chainable method
- Value can be fractional (e.g., "0.5" for half a CPU)
- Use `with_cpu_shares()` for relative CPU priority
