Fix the overwrite sudoers file issue
Change-Id: I4b109f7fdc3b8e49defed26979b04ca158842e98 Closes-Bug: #1598423
This commit is contained in:
parent
10258f138b
commit
3f79e37d21
@ -31,11 +31,11 @@ RUN ln -s ceilometer-base-source/* ceilometer \
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY ceilometer_sudoers /etc/sudoers.d/ceilometer_sudoers
|
||||
COPY ceilometer_sudoers /etc/sudoers.d/kolla_ceilometer_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla ceilometer \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/ceilometer_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_ceilometer_sudoers \
|
||||
&& touch /usr/local/bin/kolla_ceilometer_extend_start \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start /usr/local/bin/kolla_ceilometer_extend_start
|
||||
|
@ -53,11 +53,11 @@ RUN ln -s cinder-base-source/* cinder \
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY cinder_sudoers /etc/sudoers.d/cinder_sudoers
|
||||
COPY cinder_sudoers /etc/sudoers.d/kolla_cinder_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla cinder \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/cinder_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_cinder_sudoers \
|
||||
&& touch /usr/local/bin/kolla_cinder_extend_start \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start /usr/local/bin/kolla_cinder_extend_start
|
||||
|
@ -21,11 +21,11 @@ RUN apt-get -y install --no-install-recommends \
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY elasticsearch_sudoers /etc/sudoers.d/elasticsearch_sudoers
|
||||
COPY elasticsearch_sudoers /etc/sudoers.d/kolla_elasticsearch_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
RUN chmod 755 /usr/local/bin/kolla_extend_start \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/elasticsearch_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_elasticsearch_sudoers \
|
||||
&& usermod -a -G kolla elasticsearch
|
||||
|
||||
|
||||
|
@ -50,11 +50,11 @@ RUN ln -s glance-base-source/* glance \
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY glance_sudoers /etc/sudoers.d/glance_sudoers
|
||||
COPY glance_sudoers /etc/sudoers.d/kolla_glance_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla glance \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/glance_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_glance_sudoers \
|
||||
&& touch /usr/local/bin/kolla_glance_extend_start \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start /usr/local/bin/kolla_glance_extend_start
|
||||
|
@ -21,11 +21,11 @@ COPY plugins/modules /usr/share/heka/lua_modules/
|
||||
COPY plugins/decoders /usr/share/heka/lua_decoders/
|
||||
COPY plugins/encoders /usr/share/heka/lua_encoders/
|
||||
|
||||
COPY heka_sudoers /etc/sudoers.d/heka_sudoers
|
||||
COPY heka_sudoers /etc/sudoers.d/kolla_heka_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla heka \
|
||||
&& chmod 440 /etc/sudoers.d/heka_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_heka_sudoers \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start \
|
||||
&& chown -R heka: /usr/share/heka /etc/heka
|
||||
|
||||
|
@ -41,9 +41,9 @@ RUN ln -s manila-base-source/* manila \
|
||||
&& chown -R manila: /etc/manila /var/lib/manila /var/cache/manila /home/manila \
|
||||
&& sed -i 's|^exec_dirs.*|exec_dirs=/var/lib/kolla/venv/bin,/sbin,/usr/sbin,/bin,/usr/bin,/usr/local/bin,/usr/local/sbin|g' /etc/manila/rootwrap.conf
|
||||
|
||||
COPY manila_sudoers /etc/sudoers.d/manila_sudoers
|
||||
COPY manila_sudoers /etc/sudoers.d/kolla_manila_sudoers
|
||||
RUN chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/manila_sudoers
|
||||
&& chmod 440 /etc/sudoers.d/kolla_manila_sudoers
|
||||
|
||||
{% endif %}
|
||||
|
||||
|
@ -29,13 +29,13 @@ RUN apt-get -y install --no-install-recommends \
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY mariadb_sudoers /etc/sudoers.d/mariadb_sudoers
|
||||
COPY mariadb_sudoers /etc/sudoers.d/kolla_mariadb_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
COPY security_reset.expect /usr/local/bin/kolla_security_reset
|
||||
RUN chmod 755 /usr/local/bin/kolla_extend_start \
|
||||
&& chmod 755 /usr/local/bin/kolla_security_reset \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/mariadb_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_mariadb_sudoers \
|
||||
&& usermod -a -G kolla mysql
|
||||
|
||||
{{ include_footer }}
|
||||
|
@ -19,13 +19,13 @@ RUN apt-get -y install --no-install-recommends \
|
||||
RUN mkdir -p /var/lib/mongodb /home/mongodb \
|
||||
&& chown -R mongodb: /var/lib/mongodb /home/mongodb
|
||||
|
||||
COPY mongodb_sudoers /etc/sudoers.d/mongodb_sudoers
|
||||
COPY mongodb_sudoers /etc/sudoers.d/kolla_mongodb_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla mongodb \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/mongodb_sudoers
|
||||
&& chmod 440 /etc/sudoers.d/kolla_mongodb_sudoers
|
||||
|
||||
{{ include_footer }}
|
||||
|
||||
|
@ -68,11 +68,11 @@ RUN ln -s neutron-base-source/* neutron \
|
||||
|
||||
{% endif %}
|
||||
|
||||
COPY neutron_sudoers /etc/sudoers.d/neutron_sudoers
|
||||
COPY neutron_sudoers /etc/sudoers.d/kolla_neutron_sudoers
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
|
||||
RUN usermod -a -G kolla neutron \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/neutron_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_neutron_sudoers \
|
||||
&& touch /usr/local/bin/kolla_neutron_extend_start \
|
||||
&& chmod 755 /usr/local/bin/kolla_extend_start /usr/local/bin/kolla_neutron_extend_start
|
||||
|
@ -54,9 +54,9 @@ RUN ln -s nova-base-source/* nova \
|
||||
&& chown -R nova: /etc/nova /var/lib/nova \
|
||||
&& sed -i 's|^exec_dirs.*|exec_dirs=/var/lib/kolla/venv/bin,/sbin,/usr/sbin,/bin,/usr/bin,/usr/local/bin,/usr/local/sbin|g' /etc/nova/rootwrap.conf
|
||||
|
||||
COPY nova_sudoers /etc/sudoers.d/nova_sudoers
|
||||
COPY nova_sudoers /etc/sudoers.d/kolla_nova_sudoers
|
||||
RUN chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/nova_sudoers
|
||||
&& chmod 440 /etc/sudoers.d/kolla_nova_sudoers
|
||||
|
||||
{% endif %}
|
||||
|
||||
|
@ -35,11 +35,11 @@ RUN rm -rf /var/lib/rabbitmq/* \
|
||||
&& /bin/true
|
||||
|
||||
COPY extend_start.sh /usr/local/bin/kolla_extend_start
|
||||
COPY rabbitmq_sudoers /etc/sudoers.d/rabbitmq_sudoers
|
||||
COPY rabbitmq_sudoers /etc/sudoers.d/kolla_rabbitmq_sudoers
|
||||
COPY rabbitmq_get_gospel_node.py /usr/local/bin/rabbitmq_get_gospel_node
|
||||
RUN chmod 755 /usr/local/bin/kolla_extend_start /usr/local/bin/rabbitmq_get_gospel_node \
|
||||
&& chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/rabbitmq_sudoers \
|
||||
&& chmod 440 /etc/sudoers.d/kolla_rabbitmq_sudoers \
|
||||
&& usermod -a -G kolla rabbitmq
|
||||
|
||||
{{ include_footer }}
|
||||
|
@ -48,9 +48,9 @@ RUN chmod 755 /var/lib/kolla/venv/bin/swift-rootwrap \
|
||||
&& chmod 644 /etc/swift/rootwrap.conf \
|
||||
&& sed -i 's|^exec_dirs.*|exec_dirs=/var/lib/kolla/venv/bin,/sbin,/usr/sbin,/bin,/usr/bin,/usr/local/bin,/usr/local/sbin|g' /etc/swift/rootwrap.conf
|
||||
|
||||
COPY swift_sudoers /etc/sudoers.d/swift_sudoers
|
||||
COPY swift_sudoers /etc/sudoers.d/kolla_swift_sudoers
|
||||
RUN chmod 750 /etc/sudoers.d \
|
||||
&& chmod 440 /etc/sudoers.d/swift_sudoers
|
||||
&& chmod 440 /etc/sudoers.d/kolla_swift_sudoers
|
||||
|
||||
COPY build-swift-ring.py /usr/local/bin/kolla_build_swift_ring
|
||||
RUN mkdir -p /opt/swift
|
||||
|
Loading…
Reference in New Issue
Block a user