Merge "ovn: Fix log permissions"

This commit is contained in:
Zuul
2025-07-10 14:31:08 +00:00
committed by Gerrit Code Review
11 changed files with 44 additions and 0 deletions

View File

@@ -9,3 +9,5 @@ fi
if [[ $(stat -c %a /var/log/kolla/openvswitch) != "755" ]]; then
chmod 755 /var/log/kolla/openvswitch
fi
. /usr/local/bin/kolla_ovn_extend_start

View File

@@ -20,6 +20,9 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
{% endif %}
{{ macros.install_packages(ovn_controller_packages | customizable("packages")) }}
COPY extend_start.sh /usr/local/bin/kolla_ovn_extend_start
RUN chmod 644 /usr/local/bin/kolla_ovn_extend_start
{{ macros.kolla_patch_sources() }}
{% block ovn_controller_footer %}{% endblock %}

View File

@@ -0,0 +1,6 @@
#!/bin/bash
if [[ ! -r "/var/log/kolla/openvswitch/ovn-controller.log" ]]; then
touch /var/log/kolla/openvswitch/ovn-controller.log
chown openvswitch:openvswitch /var/log/kolla/openvswitch/ovn-controller.log
fi

View File

@@ -22,6 +22,8 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
COPY start_nb_db_server.sh /usr/local/bin/start-nb-db-server
RUN chmod 755 /usr/local/bin/start-nb-db-server
COPY extend_start.sh /usr/local/bin/kolla_ovn_extend_start
RUN chmod 644 /usr/local/bin/kolla_ovn_extend_start
{{ macros.kolla_patch_sources() }}

View File

@@ -0,0 +1,6 @@
#!/bin/bash
if [[ ! -r "/var/log/kolla/openvswitch/ovn-nb-db.log" ]]; then
touch /var/log/kolla/openvswitch/ovn-nb-db.log
chown openvswitch:openvswitch /var/log/kolla/openvswitch/ovn-nb-db.log
fi

View File

@@ -20,6 +20,9 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
{% endif %}
{{ macros.install_packages(ovn_northd_packages | customizable("packages")) }}
COPY extend_start.sh /usr/local/bin/kolla_ovn_extend_start
RUN chmod 644 /usr/local/bin/kolla_ovn_extend_start
{{ macros.kolla_patch_sources() }}
{% block ovn_northd_footer %}{% endblock %}

View File

@@ -0,0 +1,5 @@
#!/bin/bash
if [[ ! -r "/var/log/kolla/openvswitch/ovn-northd.log" ]]; then
touch /var/log/kolla/openvswitch/ovn-northd.log
chown openvswitch:openvswitch /var/log/kolla/openvswitch/ovn-northd.log
fi

View File

@@ -11,5 +11,8 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
RUN curl -o /usr/share/ovn/scripts/ovn-ctl https://raw.githubusercontent.com/ovn-org/ovn/refs/heads/main/utilities/ovn-ctl
{% endblock %}
COPY extend_start.sh /usr/local/bin/kolla_ovn_extend_start
RUN chmod 644 /usr/local/bin/kolla_ovn_extend_start
{% block ovn_sb_db_relay_footer %}{% endblock %}
{% block footer %}{% endblock %}

View File

@@ -0,0 +1,6 @@
#!/bin/bash
if [[ ! -r "/var/log/kolla/openvswitch/ovn-sb-relay-${RELAY_ID}.log" ]]; then
touch /var/log/kolla/openvswitch/ovn-sb-relay-${RELAY_ID}.log
chown openvswitch:openvswitch /var/log/kolla/openvswitch/ovn-sb-relay-${RELAY_ID}.log
fi

View File

@@ -22,6 +22,8 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
COPY start_sb_db_server.sh /usr/local/bin/start-sb-db-server
RUN chmod 755 /usr/local/bin/start-sb-db-server
COPY extend_start.sh /usr/local/bin/kolla_ovn_extend_start
RUN chmod 644 /usr/local/bin/kolla_ovn_extend_start
{{ macros.kolla_patch_sources() }}

View File

@@ -0,0 +1,6 @@
#!/bin/bash
if [[ ! -r "/var/log/kolla/openvswitch/ovn-sb-db.log" ]]; then
touch /var/log/kolla/openvswitch/ovn-sb-db.log
chown openvswitch:openvswitch /var/log/kolla/openvswitch/ovn-sb-db.log
fi