> ## Documentation Index
> Fetch the complete documentation index at: https://docs.webapp.io/llms.txt
> Use this file to discover all available pages before exploring further.

# MEMORY

`MEMORY [number](K|M|G)`

The `MEMORY` instruction allows you to specify how much memory your environment
uses.

This directive must always go at the top of a Layerfile.

If used in conjunction with `FROM /base-image`, the parent Layerfile must be the
one which specifies `MEMORY`, otherwise children might have to re-run steps from
the parent Layerfile.

### Examples

* Use `MEMORY 2G` to ensure at least 2 gigabytes of memory are available.
