kolla-ansible/ansible/roles/cinder/templates/cinder-volume.json.j2
Michal Nasiadka 8b3e755b85 Generate hostnqn
hostnqn is generated using to_uuid filter

Usually "nvme gen-hostnqn" command is used to generate
hostnqn, and it has the format of:
nqn.2014-08.org.nvmexpress:uuid:67dc8c8e-0262-4d81-ac51-ace7c25e4daa

"nqn.2014-08.org.nvmexpress:uuid:" is always static

Closes-Bug: #2035975

Change-Id: I6ece4fe8c18c0167a2707c24693fbe39ed15cdba
2023-10-04 10:59:47 +00:00

49 lines
1.5 KiB
Django/Jinja

{
"command": "cinder-volume --config-file /etc/cinder/cinder.conf",
"config_files": [
{
"source": "{{ container_config_directory }}/cinder.conf",
"dest": "/etc/cinder/cinder.conf",
"owner": "cinder",
"perm": "0600"
}{% if cinder_backend_ceph | bool %},
{
"source": "{{ container_config_directory }}/ceph",
"dest": "/etc/ceph",
"owner": "cinder",
"perm": "0600"
}{% endif %},
{
"source": "{{ container_config_directory }}/nfs_shares",
"dest": "/etc/cinder/nfs_shares",
"owner": "cinder",
"perm": "0600",
"optional": {{ (not enable_cinder_backend_nfs | bool) | string | lower }}
},
{
"source": "{{ container_config_directory }}/hostnqn",
"dest": "/etc/nvme/hostnqn",
"owner": "root",
"perm": "0644"
}{% if cinder_policy_file is defined %},
{
"source": "{{ container_config_directory }}/{{ cinder_policy_file }}",
"dest": "/etc/cinder/{{ cinder_policy_file }}",
"owner": "cinder",
"perm": "0600"
}{% endif %}
],
"permissions": [
{
"path": "/var/lib/cinder",
"owner": "cinder:cinder",
"recurse": true
},
{
"path": "/var/log/kolla/cinder",
"owner": "cinder:cinder",
"recurse": true
}
]
}