heat_template_version: pike description: > OpenStack containerized Neutron API service parameters: DockerNeutronApiImage: description: image type: string outputs: config_settings: description: Extra hieradata needed to log to files in the host. value: null volumes: description: extra volumes value: &neutron_api_volumes - /var/log/containers/neutron:/var/log/neutron - /var/log/containers/httpd/neutron-api:/var/log/httpd docker_config: description: Extra containers needed for logging to files in the host. value: # db sync runs before permissions set by kolla_config step_2: neutron_init_logs: image: {get_param: DockerNeutronApiImage} privileged: false user: root volumes: *neutron_api_volumes command: ['/bin/bash', '-c', 'chown -R neutron:neutron /var/log/neutron'] host_prep_tasks: description: Extra ansible tasks needed for logging to files in the host. value: - name: create persistent logs directory file: path: "{{ item }}" state: directory with_items: - /var/log/containers/neutron - /var/log/containers/httpd/neutron-api - name: neutron logs readme copy: dest: /var/log/neutron/readme.txt content: | Log files from neutron containers can be found under /var/log/containers/neutron and /var/log/containers/httpd/neutron-api. ignore_errors: true