Fix: log container password expire

move chage command to base image

Signed-off-by: DQ <dengq@vmware.com>
This commit is contained in:
DQ 2020-11-09 17:09:19 +08:00 committed by Ziming
parent 039733b200
commit 9152521b11
2 changed files with 2 additions and 3 deletions

View File

@ -17,8 +17,6 @@ COPY ./make/photon/log/start.sh /usr/local/bin/
RUN chmod +x /usr/local/bin/start.sh /etc/rsyslog.d/ && \
chown -R 10000:10000 /etc/rsyslog.conf /etc/rsyslog.d/ /run /var/lib/logrotate/
RUN chage -M 99999 root
HEALTHCHECK CMD netstat -ltun|grep 10514
VOLUME /var/log/docker/ /run/ /etc/logrotate.d/

View File

@ -3,4 +3,5 @@ FROM photon:2.0
RUN tdnf install -y cronie rsyslog logrotate shadow tar gzip sudo >> /dev/null\
&& mkdir /var/spool/rsyslog \
&& groupadd -r -g 10000 syslog && useradd --no-log-init -r -g 10000 -u 10000 syslog \
&& tdnf clean all
&& tdnf clean all \
&& chage -M 99999 root