# Resource limits in a compose file are not applying

{% hint style="info" %}
**Affected versions:** 2.14.0, 2.14.1, 2.14.2

**Fixed in:** 2.15.0 and above
{% endhint %}

#### Issue Description

When using a compose file to apply resource limits on a Docker Standalone environment, some values (such as cpus and cpu\_percent) are not applying:

```
version: "2" 

services: 
  mynginx: 
    container_name: mynginx
    image: nginx:latest
    cpus: 1
    cpu_percent: 50
```

#### Cause

This issue is [the result of a bug](https://github.com/docker/compose/issues/9268) in the version of the docker compose v2 plugin that is used in version 2.14 of Portainer.

#### Fix

Update Portainer to 2.15.0 or above.

#### Workaround

You can manually apply limits on a per-container basis after deployment [through the Portainer UI](/sts/user/docker/containers/edit.md).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.portainer.io/sts/faqs/known-issues/resource-limits-in-a-compose-file-are-not-applying.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
