harbor/make/photon/log/Dockerfile
root 6f335bdb1a Deprivilege harobr-log, harbor-db, registry image.
This change involves using non-root user to run the process of the
docker images.  Also made update in Dockerfile to make the containers
support "read-only" and introduce "HEALTHCHECK". Note the "read-only"
options are not enabled in docker-compose, to cover the very corner
case when user wants to update the container filesystem manually.

Remove read only option from docker-compose template by default
2017-11-02 23:35:06 -07:00

25 lines
595 B
Docker

FROM vmware/rsyslog-photon:8.15.0
COPY rsyslog.conf /etc/rsyslog.conf
# rotate logs weekly
# notes: file name cannot contain dot, or the script will not run
COPY rotate.sh /etc/cron.daily/rotate
# rsyslog configuration file for docker
COPY rsyslog_docker.conf /etc/rsyslog.d/
COPY start.sh /usr/local/bin/
RUN chmod +x /usr/local/bin/start.sh && \
tdnf install -y sudo net-tools && \
chown -R 10000:10000 /run
HEALTHCHECK CMD netstat -ltu|grep 10514
VOLUME /var/log/docker/ /run/
EXPOSE 10514
#CMD crond && rm -f /var/run/rsyslogd.pid && rsyslogd -n
CMD /usr/local/bin/start.sh