# Volumes issues with a php application

**URL:** <https://forums.docker.com/t/volumes-issues-with-a-php-application/50169>\
**Category:** Compose\
**Created:** [April 30, 2018, 4:01pm UTC](https://forums.docker.com/t/volumes-issues-with-a-php-application/50169 "2018-04-30T16:01:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![tpeudupin](https://avatars.discourse-cdn.com/v4/letter/t/919ad9/32.png) [@tpeudupin](https://forums.docker.com/u/tpeudupin)\
**Post date:** [April 30, 2018, 4:01pm UTC](https://forums.docker.com/t/volumes-issues-with-a-php-application/50169/1 "2018-04-30T16:01:12Z")

</div>

Hi everyone,

I’m trying to “Dockerize” a php application developped by my company and i’m facing several understanding issue on how i should use the volume.

The application have two directories that must be persistents, one containing configurations files and the second containing imported user data such as png, pdf, …

I tried to COPY the code in the image in the dockerfiles but i lost everything inside my two folder as soon as i create my container with the volumes.

I actually wants my volumes to be filled with what i copied in my image.

I know I could just make a volumes on the application itself and dont COPY the code in the image, but i’d really like to have a “stand-alone” image, without having to git clone the code every time i deploy. As the image would be used in production environment.

Could someone help me to understand what i’m doing wrong ?  
I would gladely provide any additionnal informations.

Thanks in advance.
