diff --git a/defaults/main.yml b/defaults/main.yml index 0dcf4927..00779bab 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -54,7 +54,8 @@ ironic_system_group_name: ironic ironic_system_shell: /bin/bash ironic_system_comment: ironic system user ironic_system_home_folder: "/var/lib/{{ ironic_system_user_name }}" -ironic_lock_path: /var/lock/ironic +ironic_system_slice_name: ironic +ironic_lock_dir: "{{ openstack_lock_dir | default('/run/lock') }}" # Ironic Program and Service names python_ironic_client_program_name: ironic @@ -288,8 +289,6 @@ ironic_inspector_venv_python_executable: "{{ openstack_venv_python_executable | # System info ironic_inspector_service_setup_host: "{{ openstack_service_setup_host | default('localhost') }}" -ironic_inspector_lock_path: /var/lock/ironic-inspector - ironic_inspector_service_name: ironic-inspector ironic_inspector_service_type: baremetal-introspection ironic_inspector_service_description: "Ironic Baremetal Introspection Service" diff --git a/tasks/ironic_pre_install.yml b/tasks/ironic_pre_install.yml index ee1894d7..0cac885c 100644 --- a/tasks/ironic_pre_install.yml +++ b/tasks/ironic_pre_install.yml @@ -57,20 +57,11 @@ - path: "/etc/ironic-inspector/rootwrap.d" condition: inventory_hostname in groups['ironic-inspector'] - { path: "/etc/sudoers.d", mode: "0750", owner: "root", group: "root" } - - { path: "/var/cache/ironic" } - - path: "/var/cache/ironic-inspector" - condition: inventory_hostname in groups['ironic-inspector'] - { path: "{{ ironic_system_home_folder }}" } - { path: "{{ ironic_system_home_folder }}/.ssh", mode: "0700" } - { path: "{{ ironic_system_home_folder }}/images" } - { path: "{{ ironic_system_home_folder }}/master_images" } - { path: "{{ ironic_system_home_folder }}/cache/api", mode: "0700" } - - { path: "{{ ironic_lock_path }}" } - - path: "{{ ironic_inspector_lock_path }}" - condition: inventory_hostname in groups['ironic-inspector'] - - { path: "/var/run/ironic" } - - path: "/var/run/ironic-inspector" - condition: inventory_hostname in groups['ironic-inspector'] - path: "{{ ironic_inspector_tftpboot_dir }}/pxelinux.cfg" condition: inventory_hostname in groups['ironic-inspector'] - path: "/httpboot" diff --git a/tasks/main.yml b/tasks/main.yml index f2882d8f..a77fbc21 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -128,8 +128,8 @@ systemd_user_name: "{{ ironic_system_user_name }}" systemd_group_name: "{{ ironic_system_group_name }}" systemd_tempd_prefix: openstack - systemd_slice_name: ironic - systemd_lock_path: /var/lock/ironic + systemd_slice_name: "{{ ironic_system_slice_name }}" + systemd_lock_dir: "{{ ironic_lock_dir }}" systemd_CPUAccounting: true systemd_BlockIOAccounting: true systemd_MemoryAccounting: true diff --git a/templates/ironic.conf.j2 b/templates/ironic.conf.j2 index 008ebeef..5df2ad09 100644 --- a/templates/ironic.conf.j2 +++ b/templates/ironic.conf.j2 @@ -186,7 +186,7 @@ project_domain_id = {{ ironic_service_project_domain_id }} insecure = {{ keystone_service_adminuri_insecure | bool }} [oslo_concurrency] -lock_path = {{ ironic_lock_path }} +lock_path = {{ ironic_lock_dir }}/{{ ironic_system_slice_name }} [oslo_messaging_amqp]