aboutsummaryrefslogtreecommitdiffstats
path: root/docker/ansible/roles/run_collectd
diff options
context:
space:
mode:
Diffstat (limited to 'docker/ansible/roles/run_collectd')
-rw-r--r--docker/ansible/roles/run_collectd/tasks/main.yml10
-rw-r--r--docker/ansible/roles/run_collectd/vars/main.yml10
2 files changed, 11 insertions, 9 deletions
diff --git a/docker/ansible/roles/run_collectd/tasks/main.yml b/docker/ansible/roles/run_collectd/tasks/main.yml
index 8fc27342..bf5aabf5 100644
--- a/docker/ansible/roles/run_collectd/tasks/main.yml
+++ b/docker/ansible/roles/run_collectd/tasks/main.yml
@@ -1,4 +1,4 @@
-#Copyright 2018-2019 OPNFV and Intel Corporation
+# Copyright 2018-21 Anuket, Intel Corporation and others
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -15,7 +15,7 @@
- name: remove bar-collectd container
docker_container:
- name: bar-collectd
+ name: "{{ collectd_container_name }}"
state: absent
tags:
- rm_containers
@@ -40,7 +40,7 @@
set_fact:
volumes_list:
- - /opt/collectd/etc/collectd.conf.d/:/opt/collectd/etc/collectd.conf.d
+ - /opt/collectd/etc/:/opt/collectd/etc/
- /var/run:/var/run
- /tmp:/tmp
- /var/lib/collectd:/var/lib/collectd
@@ -52,10 +52,10 @@
- name: launch collectd container
docker_container:
- name: bar-collectd
+ name: "{{ collectd_container_name }}"
image: "{{ collectd_image_name }}"
volumes: "{{ volumes_list }}"
- command: "/run_collectd.sh"
+ entrypoint: "/run_collectd.sh"
detach: yes
state: started
restart: yes
diff --git a/docker/ansible/roles/run_collectd/vars/main.yml b/docker/ansible/roles/run_collectd/vars/main.yml
index cebd0f47..26007ecf 100644
--- a/docker/ansible/roles/run_collectd/vars/main.yml
+++ b/docker/ansible/roles/run_collectd/vars/main.yml
@@ -1,4 +1,4 @@
-#Copyright 2019 OPNFV and Intel Corporation
+# Copyright 2019-21 Anuket, Intel Corporation and others
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -13,9 +13,11 @@
# limitations under the License.
---
+collectd_container_name: "bar-collectd"
default_flavor: "{{ flavor|default('stable')|string }}"
flavor_image_name: "{{
- 'barometer-collectd-master' if (default_flavor == 'master') else
- 'barometer-collectd-experimental' if (default_flavor == 'experimental')
+ 'barometer-collectd-latest' if (default_flavor == 'master' or default_flavor == 'latest') else
+ 'barometer-collectd-experimental' if (default_flavor == 'experimental') else
+ 'barometer-collectd-6' if (default_flavor == 'collectd-6')
else 'barometer-collectd' }}"
-collectd_image_name: "{{ 'opnfv/' + flavor_image_name }}"
+collectd_image_name: "{{ 'anuket/' + flavor_image_name }}"