# ConfigMap

Very similarly to the [PeristentVolumeClaim module](https://docs.garden.io/acorn-0.12/kubernetes-plugins/module-types/persistentvolumeclaim), you can also mount Kubernetes ConfigMaps on `container` modules using the `configmap` module type ([see here for the full reference](https://docs.garden.io/acorn-0.12/reference/module-types/configmap)).

Example:

```yaml
kind: Module
name: my-configmap
type: configmap
data:
  config.properties: |
    some: data
    or: something
---
kind: Module
name: my-module
type: container
services:
  - name: my-service
    volumes:
      - name: my-configmap
        module: my-configmap
        containerPath: /config
    ...
```

This mounts all the keys in the `data` field on the `my-configmap` module under the `/config` directory in the container. In this case, you'll find the file `/config/config.properties` there, with the value above (`some: data ...`) as the file contents.

You can do the same for tests and tasks using the [`tests.volumes`](https://docs.garden.io/acorn-0.12/reference/module-types/container#testsvolumes) and [`tasks.volumes`](https://docs.garden.io/acorn-0.12/reference/module-types/container#tasksvolumes) fields. `configmap` volumes can of course also be referenced in `kubernetes` and `helm` modules, since they are deployed as standard ConfigMap resources.

Take a look at the [`configmap` module type](https://docs.garden.io/acorn-0.12/reference/module-types/configmap) and [`container` module](https://docs.garden.io/acorn-0.12/reference/module-types/container#servicesvolumes) docs for more details.
