summaryrefslogtreecommitdiffstats
path: root/docker/services
diff options
context:
space:
mode:
authorJuan Antonio Osorio Robles <jaosorior@redhat.com>2017-10-27 10:22:01 +0300
committerJuan Antonio Osorio Robles <jaosorior@redhat.com>2017-10-30 12:55:49 +0000
commit5f79927c58d342cf29417cef4b6e9111854224af (patch)
tree585729fa2ebad9b285803396ff99cf8380e6c5b8 /docker/services
parent9dfec11795703b43991e06ef880b52cd0b3a5eb4 (diff)
persist memcached logs in /var/log/containers/memcached/memcached.log
We used to bind-mount /var/log/memcached.log, but this resulted in the file being createdin the memcached container as a directory, since this file didn't exist. This commit takes the approach of other containers and gets the logs to a memcached directory in /var/log/containers. Change-Id: I926b65fa557ad56b4faa2be34452b58f7b01247a Closes-Bug: #1720183 (cherry picked from commit 5020f38301a9a0a70f34878196250e24fc639dec)
Diffstat (limited to 'docker/services')
-rw-r--r--docker/services/memcached.yaml6
1 files changed, 3 insertions, 3 deletions
diff --git a/docker/services/memcached.yaml b/docker/services/memcached.yaml
index c78b85a6..817f9ec7 100644
--- a/docker/services/memcached.yaml
+++ b/docker/services/memcached.yaml
@@ -80,8 +80,8 @@ outputs:
user: root
volumes:
- /var/lib/config-data/memcached/etc/sysconfig/memcached:/etc/sysconfig/memcached:ro
- - /var/log/memcached.log:/var/log/memcached.log
- command: ['/bin/bash', '-c', 'source /etc/sysconfig/memcached; chown ${USER} /var/log/memcached.log']
+ - /var/log/containers/memcached:/var/log/
+ command: ['/bin/bash', '-c', 'source /etc/sysconfig/memcached; touch /var/log/memcached.log && chown ${USER} /var/log/memcached.log']
memcached:
start_order: 1
image: *memcached_image
@@ -93,7 +93,7 @@ outputs:
- {get_attr: [ContainersCommon, volumes]}
-
- /var/lib/config-data/memcached/etc/sysconfig/memcached:/etc/sysconfig/memcached:ro
- # TODO(bogdando) capture memcached syslog logs from a container
+ - /var/log/containers/memcached:/var/log/
command: ['/bin/bash', '-c', 'source /etc/sysconfig/memcached; /usr/bin/memcached -p ${PORT} -u ${USER} -m ${CACHESIZE} -c ${MAXCONN} $OPTIONS']
upgrade_tasks:
- name: Stop and disable memcached service