From f820a22a4f7fbe6374db27bf9cf9ba5d98f600e7 Mon Sep 17 00:00:00 2001 From: Jose Pabl Domingo Aramburo Sanchez Date: Sun, 12 Aug 2018 01:25:11 +0000 Subject: [PATCH] [add] Volumes directory --- docker-compose.yml | 7 +++++-- volumes/.gitignore | 2 ++ volumes/README.md | 1 + 3 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 volumes/.gitignore create mode 100644 volumes/README.md diff --git a/docker-compose.yml b/docker-compose.yml index edc24df..aa5a8d6 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,6 +5,8 @@ services: build: api-payroll/ ports: - "8085:80" + volumes: + - ./volumes/apache-logs:/var/log/apache2 depends_on: - mysql mysql: @@ -16,10 +18,11 @@ services: ports: - "3307:3307" volumes: - - my-datavolume:/var/lib/mysql + - ./volumes/mysql-data:/var/lib/mysql environment: MYSQL_ROOT_PASSWORD: '12345678' MYSQL_USER: 'sloth' MYSQL_PASS: '12345678' volumes: - my-datavolume: + mysql-data: + apache-logs: diff --git a/volumes/.gitignore b/volumes/.gitignore new file mode 100644 index 0000000..9e750a3 --- /dev/null +++ b/volumes/.gitignore @@ -0,0 +1,2 @@ +mysql-data/ +apache-logs/ diff --git a/volumes/README.md b/volumes/README.md new file mode 100644 index 0000000..3c5b13b --- /dev/null +++ b/volumes/README.md @@ -0,0 +1 @@ +# Do not delete this directory, it'll contain the volumes created by the containers