diff options
author | Pradeep Kilambi <pkilambi@redhat.com> | 2017-09-06 12:14:12 -0400 |
---|---|---|
committer | Pradeep Kilambi <pkilambi@redhat.com> | 2017-09-11 12:51:14 +0000 |
commit | 1dd48af650fc5b768243715c712f1c524626f2ba (patch) | |
tree | b6f54959a89807ea6abe337a8ac68ad482d53dac /docker | |
parent | 39bb4cf3e960cbbe3390175b230aa32a5d795a4c (diff) |
Enable Ceilometer agent logging for containers
Change-Id: Ibeb28d7c497b02253d00a74257989cefba2b0cc4
(cherry picked from commit fc44ee6ff3553754c618349df3be7544b17e9c5f)
Diffstat (limited to 'docker')
-rw-r--r-- | docker/services/ceilometer-agent-central.yaml | 7 | ||||
-rw-r--r-- | docker/services/ceilometer-agent-compute.yaml | 8 | ||||
-rw-r--r-- | docker/services/ceilometer-agent-notification.yaml | 8 |
3 files changed, 20 insertions, 3 deletions
diff --git a/docker/services/ceilometer-agent-central.yaml b/docker/services/ceilometer-agent-central.yaml index 424c316f..d772462d 100644 --- a/docker/services/ceilometer-agent-central.yaml +++ b/docker/services/ceilometer-agent-central.yaml @@ -69,7 +69,7 @@ outputs: config_image: {get_param: DockerCeilometerConfigImage} kolla_config: /var/lib/kolla/config_files/ceilometer_agent_central.json: - command: /usr/bin/ceilometer-polling --polling-namespaces central + command: /usr/bin/ceilometer-polling --polling-namespaces central --logfile /var/log/ceilometer/central.log config_files: - source: "/var/lib/kolla/config_files/src/*" dest: "/" @@ -116,6 +116,11 @@ outputs: - '/usr/bin/bootstrap_host_exec' - 'ceilometer_agent_central' - "su ceilometer -s /bin/bash -c 'for n in {1..10}; do /usr/bin/ceilometer-upgrade --skip-metering-database && exit 0 || sleep 5; done; exit 1'" + host_prep_tasks: + - name: create persistent logs directory + file: + path: /var/log/containers/ceilometer + state: directory upgrade_tasks: - name: Stop and disable ceilometer agent central service tags: step2 diff --git a/docker/services/ceilometer-agent-compute.yaml b/docker/services/ceilometer-agent-compute.yaml index 535b1693..c800b44f 100644 --- a/docker/services/ceilometer-agent-compute.yaml +++ b/docker/services/ceilometer-agent-compute.yaml @@ -69,7 +69,7 @@ outputs: config_image: {get_param: DockerCeilometerConfigImage} kolla_config: /var/lib/kolla/config_files/ceilometer_agent_compute.json: - command: /usr/bin/ceilometer-polling --polling-namespaces compute + command: /usr/bin/ceilometer-polling --polling-namespaces compute --logfile /var/log/ceilometer/compute.log config_files: - source: "/var/lib/kolla/config_files/src/*" dest: "/" @@ -89,8 +89,14 @@ outputs: - /var/lib/kolla/config_files/ceilometer_agent_compute.json:/var/lib/kolla/config_files/config.json:ro - /var/lib/config-data/puppet-generated/ceilometer/:/var/lib/kolla/config_files/src:ro - /var/run/libvirt:/var/run/libvirt:ro + - /var/log/containers/ceilometer:/var/log/ceilometer environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS + host_prep_tasks: + - name: create persistent logs directory + file: + path: /var/log/containers/ceilometer + state: directory upgrade_tasks: - name: Check if openstack-ceilometer-compute is deployed command: systemctl is-enabled openstack-ceilometer-compute diff --git a/docker/services/ceilometer-agent-notification.yaml b/docker/services/ceilometer-agent-notification.yaml index 7f1d442a..d8afe695 100644 --- a/docker/services/ceilometer-agent-notification.yaml +++ b/docker/services/ceilometer-agent-notification.yaml @@ -69,7 +69,7 @@ outputs: config_image: {get_param: DockerCeilometerConfigImage} kolla_config: /var/lib/kolla/config_files/ceilometer_agent_notification.json: - command: /usr/bin/ceilometer-agent-notification + command: /usr/bin/ceilometer-agent-notification --logfile /var/log/ceilometer/agent-notification.log config_files: - source: "/var/lib/kolla/config_files/src/*" dest: "/" @@ -96,8 +96,14 @@ outputs: - - /var/lib/kolla/config_files/ceilometer_agent_notification.json:/var/lib/kolla/config_files/config.json:ro - /var/lib/config-data/puppet-generated/ceilometer/:/var/lib/kolla/config_files/src:ro + - /var/log/containers/ceilometer:/var/log/ceilometer environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS + host_prep_tasks: + - name: create persistent logs directory + file: + path: /var/log/containers/ceilometer + state: directory upgrade_tasks: - name: Stop and disable ceilometer agent notification service tags: step2 |