Merge "Add vitrage-persistor service"
This commit is contained in:
commit
bb6e23fb29
@ -711,6 +711,9 @@ vitrage
|
|||||||
[vitrage-ml:children]
|
[vitrage-ml:children]
|
||||||
vitrage
|
vitrage
|
||||||
|
|
||||||
|
[vitrage-persistor:children]
|
||||||
|
vitrage
|
||||||
|
|
||||||
# Blazar
|
# Blazar
|
||||||
[blazar-api:children]
|
[blazar-api:children]
|
||||||
blazar
|
blazar
|
||||||
|
@ -730,6 +730,9 @@ vitrage
|
|||||||
[vitrage-ml:children]
|
[vitrage-ml:children]
|
||||||
vitrage
|
vitrage
|
||||||
|
|
||||||
|
[vitrage-persistor:children]
|
||||||
|
vitrage
|
||||||
|
|
||||||
# Blazar
|
# Blazar
|
||||||
[blazar-api:children]
|
[blazar-api:children]
|
||||||
blazar
|
blazar
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
rewriterule28 programname ^(ironic-api|ironic-conductor|ironic-inspector)$ openstack_python
|
rewriterule28 programname ^(ironic-api|ironic-conductor|ironic-inspector)$ openstack_python
|
||||||
rewriterule29 programname ^(panko-api|panko-dbsync)$ openstack_python
|
rewriterule29 programname ^(panko-api|panko-dbsync)$ openstack_python
|
||||||
rewriterule30 programname ^(tacker-server|tacker-conductor)$ openstack_python
|
rewriterule30 programname ^(tacker-server|tacker-conductor)$ openstack_python
|
||||||
rewriterule31 programname ^(vitrage-ml|vitrage-notifier|vitrage-graph)$ openstack_python
|
rewriterule31 programname ^(vitrage-ml|vitrage-notifier|vitrage-graph|vitrage-persistor)$ openstack_python
|
||||||
rewriterule32 programname ^(blazar-api|blazar-manager)$ openstack_python
|
rewriterule32 programname ^(blazar-api|blazar-manager)$ openstack_python
|
||||||
rewriterule33 programname ^(cyborg-api|cyborg-conductor|cyborg-agent)$ openstack_python
|
rewriterule33 programname ^(cyborg-api|cyborg-conductor|cyborg-agent)$ openstack_python
|
||||||
rewriterule34 programname ^(monasca-api|monasca-notification|monasca-persister|agent-collector|agent-forwarder|agent-statsd)$ openstack_python
|
rewriterule34 programname ^(monasca-api|monasca-notification|monasca-persister|agent-collector|agent-forwarder|agent-statsd)$ openstack_python
|
||||||
|
@ -158,7 +158,7 @@
|
|||||||
</rule>
|
</rule>
|
||||||
<rule>
|
<rule>
|
||||||
key programname
|
key programname
|
||||||
pattern ^(vitrage-ml|vitrage-notifier|vitrage-graph)$
|
pattern ^(vitrage-ml|vitrage-notifier|vitrage-graph|vitrage-persistor)$
|
||||||
tag openstack_python
|
tag openstack_python
|
||||||
</rule>
|
</rule>
|
||||||
<rule>
|
<rule>
|
||||||
|
@ -41,6 +41,13 @@ vitrage_services:
|
|||||||
image: "{{ vitrage_ml_image_full }}"
|
image: "{{ vitrage_ml_image_full }}"
|
||||||
volumes: "{{ vitrage_ml_default_volumes + vitrage_ml_extra_volumes }}"
|
volumes: "{{ vitrage_ml_default_volumes + vitrage_ml_extra_volumes }}"
|
||||||
dimensions: "{{ vitrage_ml_dimensions }}"
|
dimensions: "{{ vitrage_ml_dimensions }}"
|
||||||
|
vitrage-persistor:
|
||||||
|
container_name: vitrage_persistor
|
||||||
|
group: vitrage-persistor
|
||||||
|
enabled: true
|
||||||
|
image: "{{ vitrage_persistor_image_full }}"
|
||||||
|
volumes: "{{ vitrage_persistor_default_volumes + vitrage_persistor_extra_volumes }}"
|
||||||
|
dimensions: "{{ vitrage_persistor_dimensions }}"
|
||||||
|
|
||||||
####################
|
####################
|
||||||
## Database
|
## Database
|
||||||
@ -72,10 +79,15 @@ vitrage_ml_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ dock
|
|||||||
vitrage_ml_tag: "{{ vitrage_tag }}"
|
vitrage_ml_tag: "{{ vitrage_tag }}"
|
||||||
vitrage_ml_image_full: "{{ vitrage_ml_image }}:{{ vitrage_ml_tag }}"
|
vitrage_ml_image_full: "{{ vitrage_ml_image }}:{{ vitrage_ml_tag }}"
|
||||||
|
|
||||||
|
vitrage_persistor_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/{{ kolla_base_distro }}-{{ vitrage_install_type }}-vitrage-persistor"
|
||||||
|
vitrage_persistor_tag: "{{ vitrage_tag }}"
|
||||||
|
vitrage_persistor_image_full: "{{ vitrage_persistor_image }}:{{ vitrage_persistor_tag }}"
|
||||||
|
|
||||||
vitrage_api_dimensions: "{{ default_container_dimensions }}"
|
vitrage_api_dimensions: "{{ default_container_dimensions }}"
|
||||||
vitrage_notifier_dimensions: "{{ default_container_dimensions }}"
|
vitrage_notifier_dimensions: "{{ default_container_dimensions }}"
|
||||||
vitrage_graph_dimensions: "{{ default_container_dimensions }}"
|
vitrage_graph_dimensions: "{{ default_container_dimensions }}"
|
||||||
vitrage_ml_dimensions: "{{ default_container_dimensions }}"
|
vitrage_ml_dimensions: "{{ default_container_dimensions }}"
|
||||||
|
vitrage_persistor_dimensions: "{{ default_container_dimensions }}"
|
||||||
|
|
||||||
vitrage_api_default_volumes:
|
vitrage_api_default_volumes:
|
||||||
- "{{ node_config_directory }}/vitrage-api/:{{ container_config_directory }}/:ro"
|
- "{{ node_config_directory }}/vitrage-api/:{{ container_config_directory }}/:ro"
|
||||||
@ -101,12 +113,19 @@ vitrage_ml_default_volumes:
|
|||||||
- "{{ '/etc/timezone:/etc/timezone:ro' if kolla_base_distro in ['debian', 'ubuntu'] else '' }}"
|
- "{{ '/etc/timezone:/etc/timezone:ro' if kolla_base_distro in ['debian', 'ubuntu'] else '' }}"
|
||||||
- "{{ kolla_dev_repos_directory ~ '/vitrage/vitrage:/var/lib/kolla/venv/lib/python' ~ distro_python_version ~ '/site-packages/vitrage' if vitrage_dev_mode | bool else '' }}"
|
- "{{ kolla_dev_repos_directory ~ '/vitrage/vitrage:/var/lib/kolla/venv/lib/python' ~ distro_python_version ~ '/site-packages/vitrage' if vitrage_dev_mode | bool else '' }}"
|
||||||
- "kolla_logs:/var/log/kolla/"
|
- "kolla_logs:/var/log/kolla/"
|
||||||
|
vitrage_persistor_default_volumes:
|
||||||
|
- "{{ node_config_directory }}/vitrage-persistor/:{{ container_config_directory }}/:ro"
|
||||||
|
- "/etc/localtime:/etc/localtime:ro"
|
||||||
|
- "{{ '/etc/timezone:/etc/timezone:ro' if kolla_base_distro in ['debian', 'ubuntu'] else '' }}"
|
||||||
|
- "{{ kolla_dev_repos_directory ~ '/vitrage/vitrage:/var/lib/kolla/venv/lib/python' ~ distro_python_version ~ '/site-packages/vitrage' if vitrage_dev_mode | bool else '' }}"
|
||||||
|
- "kolla_logs:/var/log/kolla/"
|
||||||
|
|
||||||
vitrage_extra_volumes: "{{ default_extra_volumes }}"
|
vitrage_extra_volumes: "{{ default_extra_volumes }}"
|
||||||
vitrage_api_extra_volumes: "{{ vitrage_extra_volumes }}"
|
vitrage_api_extra_volumes: "{{ vitrage_extra_volumes }}"
|
||||||
vitrage_notifier_extra_volumes: "{{ vitrage_extra_volumes }}"
|
vitrage_notifier_extra_volumes: "{{ vitrage_extra_volumes }}"
|
||||||
vitrage_graph_extra_volumes: "{{ vitrage_extra_volumes }}"
|
vitrage_graph_extra_volumes: "{{ vitrage_extra_volumes }}"
|
||||||
vitrage_ml_extra_volumes: "{{ vitrage_extra_volumes }}"
|
vitrage_ml_extra_volumes: "{{ vitrage_extra_volumes }}"
|
||||||
|
vitrage_persistor_extra_volumes: "{{ vitrage_extra_volumes }}"
|
||||||
|
|
||||||
####################
|
####################
|
||||||
# OpenStack
|
# OpenStack
|
||||||
|
@ -58,3 +58,18 @@
|
|||||||
dimensions: "{{ service.dimensions }}"
|
dimensions: "{{ service.dimensions }}"
|
||||||
when:
|
when:
|
||||||
- kolla_action != "config"
|
- kolla_action != "config"
|
||||||
|
|
||||||
|
- name: Restart vitrage-persistor container
|
||||||
|
vars:
|
||||||
|
service_name: "vitrage-persistor"
|
||||||
|
service: "{{ vitrage_services[service_name] }}"
|
||||||
|
become: true
|
||||||
|
kolla_docker:
|
||||||
|
action: "recreate_or_restart_container"
|
||||||
|
common_options: "{{ docker_common_options }}"
|
||||||
|
name: "{{ service.container_name }}"
|
||||||
|
image: "{{ service.image }}"
|
||||||
|
volumes: "{{ service.volumes | reject('equalto', '') | list }}"
|
||||||
|
dimensions: "{{ service.dimensions }}"
|
||||||
|
when:
|
||||||
|
- kolla_action != "config"
|
||||||
|
@ -6,7 +6,8 @@
|
|||||||
when: inventory_hostname in groups['vitrage-api'] or
|
when: inventory_hostname in groups['vitrage-api'] or
|
||||||
inventory_hostname in groups['vitrage-ml'] or
|
inventory_hostname in groups['vitrage-ml'] or
|
||||||
inventory_hostname in groups['vitrage-graph'] or
|
inventory_hostname in groups['vitrage-graph'] or
|
||||||
inventory_hostname in groups['vitrage-notifier']
|
inventory_hostname in groups['vitrage-notifier'] or
|
||||||
|
inventory_hostname in groups['vitrage-persistor']
|
||||||
|
|
||||||
- include_tasks: clone.yml
|
- include_tasks: clone.yml
|
||||||
when: vitrage_dev_mode | bool
|
when: vitrage_dev_mode | bool
|
||||||
|
24
ansible/roles/vitrage/templates/vitrage-persistor.json.j2
Normal file
24
ansible/roles/vitrage/templates/vitrage-persistor.json.j2
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
{
|
||||||
|
"command": "vitrage-persistor --config-file /etc/vitrage/vitrage.conf",
|
||||||
|
"config_files": [
|
||||||
|
{
|
||||||
|
"source": "{{ container_config_directory }}/vitrage.conf",
|
||||||
|
"dest": "/etc/vitrage/vitrage.conf",
|
||||||
|
"owner": "vitrage",
|
||||||
|
"perm": "0644"
|
||||||
|
}{% if vitrage_policy_file is defined %},
|
||||||
|
{
|
||||||
|
"source": "{{ container_config_directory }}/{{ vitrage_policy_file }}",
|
||||||
|
"dest": "/etc/vitrage/{{ vitrage_policy_file }}",
|
||||||
|
"owner": "vitrage",
|
||||||
|
"perm": "0600"
|
||||||
|
}{% endif %}
|
||||||
|
],
|
||||||
|
"permissions": [
|
||||||
|
{
|
||||||
|
"path": "/var/log/kolla/vitrage",
|
||||||
|
"owner": "vitrage:vitrage",
|
||||||
|
"recurse": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
6
releasenotes/notes/bug-1869319-66905f50871ac6b1.yaml
Normal file
6
releasenotes/notes/bug-1869319-66905f50871ac6b1.yaml
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- |
|
||||||
|
Adds missing ``vitrage-persistor`` service, required by Vitrage
|
||||||
|
deployments for storing data.
|
||||||
|
`LP#1869319 <https://launchpad.net/bugs/1869319>`__
|
Loading…
Reference in New Issue
Block a user