ERR [undef] Can't insert log entry in Docker Container

Forum for questions and support relating to the 1.32.x releases only.
Post Reply
Kinoha
Posts: 6
Joined: Mon Feb 02, 2015 3:22 pm

ERR [undef] Can't insert log entry in Docker Container

Post by Kinoha »

I use ZoneMinder via Docker, the host is under Archlinux.
The database is also a Docker container.

I left this Dockerfile(see below), I simply removed installation of mariadb-server.

I loaded the sql files on the command line as shown below.
I checked the presence of triggers and other mysql parameters (sql_mode...) and 40_firstrun.sh (comment mariadb lines).
All my containers are in host network mode (rhasspy, nodered, ...).

The problem is that I cannot add a camera :(
Tesla = hostname of host, docker logs zoneminder:

Code: Select all

Jan  8 09:32:03 tesla undef[695]: ERR [undef] [Can't insert log entry: sql(INSERT INTO Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) VALUES ( 1578472323.718625, 'undef', 0, 695, -2, 'ERR', 'Can\'t connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed', 'zm_db.cpp', 68 )) error(MySQL server has gone away)]
Jan  8 09:32:03 tesla undef[695]: ERR [undef] [Can't connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed]
Jan  8 09:32:03 tesla undef[695]: ERR [undef] [Can't connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed]
Jan  8 09:32:03 tesla undef[695]: ERR [undef] [Can't insert log entry: sql(INSERT INTO Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) VALUES ( 1578472323.719125, 'undef', 0, 695, -2, 'ERR', 'Can\'t run query: MySQL server has gone away', 'zm_config.cpp', 344 )) error(MySQL server has gone away)]
Jan  8 09:32:03 tesla undef[695]: ERR [undef] [Can't connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed]
Jan  8 09:32:03 tesla undef[695]: ERR [undef] [Can't run query: MySQL server has gone away]
Jan  8 09:32:03 tesla undef[699]: ERR [undef] [Can't insert log entry: sql(INSERT INTO Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) VALUES ( 1578472323.985002, 'undef', 0, 699, -2, 'ERR', 'Can\'t connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed', 'zm_db.cpp', 68 )) error(MySQL server has gone away)]
Jan  8 09:32:03 tesla undef[699]: ERR [undef] [Can't connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed]
Jan  8 09:32:03 tesla undef[699]: ERR [undef] [Can't connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed]
Jan  8 09:32:03 tesla undef[699]: ERR [undef] [Can't insert log entry: sql(INSERT INTO Logs ( TimeKey, Component, ServerId, Pid, Level, Code, Message, File, Line ) VALUES ( 1578472323.985725, 'undef', 0, 699, -2, 'ERR', 'Can\'t run query: MySQL server has gone away', 'zm_config.cpp', 344 )) error(MySQL server has gone away)]
Jan  8 09:32:03 tesla undef[699]: ERR [undef] [Can't connect to server: SSL connection error: SSL_CTX_set_default_verify_paths failed]
Jan  8 09:32:03 tesla undef[699]: ERR [undef] [Can't run query: MySQL server has gone away]
From host:

Code: Select all

docker run mariadb mysql --version
mysql  Ver 14.14 Distrib 5.7.28, for Linux (x86_64) using  EditLine wrapper
From zoneminder container:

Code: Select all

mysql -h 127.0.0.1 -u zoneminder -p zoneminder < /usr/share/zoneminder/db/zm_update-1.32.3.sql
Enter password:
Column Protocol already exists in Servers
Column Protocol already exists in Servers
Column PathToIndex already exists in Servers
Column PathToIndex already exists in Servers
Column PathToZMS already exists in Servers
Column PathToZMS already exists in Servers
Column PathToApi already exists in Servers
Column PathToApi already exists in Servers
Column Port already exists in Servers
Column Port already exists in Servers

mysql --host=127.0.0.1 -u root -p -e 'SHOW GRANTS FOR "zoneminder"@"%";'
Enter password:
+---------------------------------------------------------------------------------+
| Grants for zoneminder@%                                                         |
+---------------------------------------------------------------------------------+
| GRANT USAGE ON *.* TO 'zoneminder'@'%'                                          |
| GRANT ALL PRIVILEGES ON `zoneminder`.* TO 'zoneminder'@'%' WITH GRANT OPTION    |
| GRANT ALL PRIVILEGES ON `zoneminder\_%`.* TO 'zoneminder'@'%' WITH GRANT OPTION |
+---------------------------------------------------------------------------------+

ps aux
USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root           1  0.0  0.0  34120 10732 ?        Ss   10:44   0:00 /usr/bin/python3 -u /sbin/my_init
root          25  0.0  0.0  72380  7524 ?        S    10:44   0:00 /usr/sbin/syslog-ng --pidfile /var/run/syslog-ng.pid -F --no-caps
root         479  0.0  0.2 416700 37844 ?        Ss   10:44   0:00 /usr/sbin/apache2 -k start
www-data     484  0.0  0.1 420520 18148 ?        S    10:44   0:00 /usr/sbin/apache2 -k start
www-data     485  0.0  0.1 420940 18596 ?        S    10:44   0:00 /usr/sbin/apache2 -k start
www-data     486  0.0  0.1 420900 17116 ?        S    10:44   0:00 /usr/sbin/apache2 -k start
www-data     487  0.0  0.1 420500 18456 ?        S    10:44   0:00 /usr/sbin/apache2 -k start
www-data     488  0.0  0.1 420892 17028 ?        S    10:44   0:00 /usr/sbin/apache2 -k start
www-data     512  3.9  0.1  89648 19620 ?        S    10:44   0:05 /usr/bin/perl -wT /usr/bin/zmdc.pl startup
www-data     513  0.0  0.0 416852 10736 ?        S    10:44   0:00 /usr/sbin/apache2 -k start
www-data     539  4.3  0.2 110876 35068 ?        S    10:44   0:06 /usr/bin/perl -wT /usr/bin/zmfilter.pl --filter_id=1 --daemon
www-data     543  4.3  0.2 110848 35092 ?        S    10:44   0:06 /usr/bin/perl -wT /usr/bin/zmfilter.pl --filter_id=2 --daemon
www-data     547  4.2  0.1  92124 20532 ?        S    10:44   0:05 /usr/bin/perl -wT /usr/bin/zmwatch.pl
www-data     551  4.2  0.1  91396 24136 ?        S    10:44   0:05 /usr/bin/perl -w /usr/bin/zmupdate.pl -c
www-data     555  4.2  0.1  85688 20152 ?        S    10:44   0:05 /usr/bin/perl -wT /usr/bin/zmstats.pl
root         559  0.0  0.0   4388  1096 ?        S    10:44   0:00 /usr/bin/runsvdir -P /etc/service
root         560  0.0  0.0   4236   688 ?        Ss   10:44   0:00 runsv cron
root         561  0.0  0.0   4236   688 ?        Ss   10:44   0:00 runsv sshd
root         562  0.0  0.0  30976  2856 ?        S    10:44   0:00 /usr/sbin/cron -f
www-data     591  0.1  0.1 420492 16728 ?        S    10:45   0:00 /usr/sbin/apache2 -k start
www-data     592  0.0  0.0 416732  8784 ?        S    10:45   0:00 /usr/sbin/apache2 -k start
www-data     593  0.0  0.0 416732  8784 ?        S    10:45   0:00 /usr/sbin/apache2 -k start
www-data     594  0.0  0.0 416732  8784 ?        S    10:45   0:00 /usr/sbin/apache2 -k start
root         619  0.1  0.0  23172  3676 pts/0    Ss   10:46   0:00 bash
root         633  0.0  0.0  39332  3288 pts/0    R+   10:46   0:00 ps aux
Start up log:

Code: Select all

*** Running /etc/my_init.d/00_regen_ssh_host_keys.sh...
*** Running /etc/my_init.d/05_set_the_time.sh...
Setting the timezone to : Europe/Paris
/etc/my_init.d/05_set_the_time.sh: line 9: /etc/timezone: Read-only file system
/var/lib/dpkg/info/tzdata.config: 334: /var/lib/dpkg/info/tzdata.config: cannot create /etc/timezone: Read-only file system
Date: Wed Jan  8 09:11:27 CET 2020
*** Running /etc/my_init.d/06_set_php_time.sh...
*** Running /etc/my_init.d/10_syslog-ng.init...
Jan  8 09:11:27 tesla syslog-ng[25]: syslog-ng starting up; version='3.5.6'
Jan  8 09:11:28 tesla syslog-ng[25]: EOF on control channel, closing connection;
*** Running /etc/my_init.d/20_apt_update.sh...
Hit:1 http://ppa.launchpad.net/iconnor/zoneminder-1.32/ubuntu xenial InRelease
Hit:2 http://archive.ubuntu.com/ubuntu xenial InRelease
Get:3 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
Get:4 http://ppa.launchpad.net/ondrej/apache2/ubuntu xenial InRelease [23.8 kB]
Get:5 http://security.ubuntu.com/ubuntu xenial-security InRelease [109 kB]
Hit:6 http://ppa.launchpad.net/ondrej/php/ubuntu xenial InRelease
Get:7 http://archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB]
Get:8 http://archive.ubuntu.com/ubuntu xenial-updates/main Sources [435 kB]
Get:9 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [1408 kB]
Get:10 http://security.ubuntu.com/ubuntu xenial-security/main Sources [198 kB]
Get:11 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages [1030 kB]
Fetched 3420 kB in 2s (1442 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
Calculating upgrade...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists...
Building dependency tree...
Reading state information...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
*** Running /etc/my_init.d/30_gen_ssl_keys.sh...
using existing keys in "/config/keys"
*** Running /etc/my_init.d/40_firstrun.sh...
Using existing conf folder
Moving zm.conf to config folder
Moving zmeventnotification.ini
Moving secrets.ini
Moving the event notification server
Using existing ssmtp folder
Copy /config/control/ scripts to /usr/share/perl5/ZoneMinder/Control/
Copy /config/conf/ scripts to /etc/zm/conf.d/
Creating symbolink links
Using existing data directory for events
Using existing data directory for images
Using existing data directory for temp
Using existing data directory for cache
no crontab for root
Setting shared memory to : "50%" of 16214628 bytes
mount: wrong fs type, bad option, bad superblock on tmpfs,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail or so.
Starting services...
Database already at version 1.32.3, update skipped.
Freshening configuration in database
Loading config from DB 223 entries
Saving config to DB 223 entries
 * Starting Apache httpd web server apache2
 *
Starting ZoneMinder:
Jan  8 09:11:39 tesla zmpkg[500]: INF [Command: start]
Jan  8 09:11:39 tesla zmpkg[500]: INF [Sanity checking States table...]
Jan  8 09:11:39 tesla zmpkg[500]: INF [Command: start]
Jan  8 09:11:45 tesla zmdc[512]: INF [Server starting at 20/01/08 09:11:45]
Jan  8 09:11:46 tesla zmdc[512]: INF [Socket should be open at /var/run/zm/zmdc.sock]
Jan  8 09:11:46 tesla zmpkg[500]: INF [Single server configuration detected. Starting up services.]
Jan  8 09:11:46 tesla zmdc[512]: INF ['zmfilter.pl --filter_id=1 --daemon' starting at 20/01/08 09:11:46, pid = 538]
Jan  8 09:11:46 tesla zmdc[538]: INF ['zmfilter.pl --filter_id=1 --daemon' started at 20/01/08 09:11:46]
Jan  8 09:11:47 tesla zmdc[512]: INF ['zmfilter.pl --filter_id=2 --daemon' starting at 20/01/08 09:11:47, pid = 542]
Jan  8 09:11:47 tesla zmdc[542]: INF ['zmfilter.pl --filter_id=2 --daemon' started at 20/01/08 09:11:47]
Jan  8 09:11:47 tesla zmdc[512]: INF ['zmwatch.pl' starting at 20/01/08 09:11:47, pid = 546]
Jan  8 09:11:47 tesla zmdc[546]: INF ['zmwatch.pl' started at 20/01/08 09:11:47]
Jan  8 09:11:47 tesla zmdc[550]: INF ['zmupdate.pl -c' started at 20/01/08 09:11:47]
Jan  8 09:11:47 tesla zmdc[512]: INF ['zmupdate.pl -c' starting at 20/01/08 09:11:47, pid = 550]
Jan  8 09:11:48 tesla zmdc[554]: INF ['zmstats.pl' started at 20/01/08 09:11:48]
Jan  8 09:11:48 tesla zmdc[512]: INF ['zmstats.pl' starting at 20/01/08 09:11:48, pid = 554]
ZoneMinder started successfully
*** Running /etc/my_init.d/999_advanced_script.sh...
*** Running /etc/rc.local...
*** Booting runit daemon...
*** Runit started as PID 558
Jan  8 09:11:48 tesla cron[561]: (CRON) INFO (pidfile fd = 3)
Jan  8 09:11:48 tesla cron[561]: (CRON) INFO (Running @reboot jobs)
Jan  8 09:11:54 tesla zmfilter_1[538]: INF [Scanning for events using filter id '1']
Jan  8 09:11:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:11:54 tesla zmfilter_2[542]: INF [Scanning for events using filter id '2']
Jan  8 09:11:54 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:11:55 tesla zmwatch[546]: INF [Watchdog starting, pausing for 30 seconds]
Jan  8 09:11:55 tesla zmstats[554]: INF [Stats Daemon starting in 30 seconds]
Jan  8 09:12:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:12:54 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:13:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:13:54 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:14:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:14:54 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:15:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:15:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:16:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:16:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:17:01 tesla CRON[594]: (root) CMD (   cd / && run-parts --report /etc/cron.hourly)
Jan  8 09:17:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:17:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:18:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:18:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:19:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:19:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:20:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:20:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:21:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:21:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:22:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:22:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
Jan  8 09:23:54 tesla zmfilter_1[538]: INF [Checking filter PurgeWhenFull delete returned 0 events ]
Jan  8 09:23:55 tesla zmfilter_2[542]: INF [Checking filter Update DiskSpace update disk space returned 0 events ]
/etc/zm/zm.conf

Code: Select all

# ==========================================================================
#
# ZoneMinder Base Configuration
#
# ==========================================================================
#
# *** DO NOT EDIT THIS FILE ***
#
# To make custom changes to the variables below, create a new configuration
# file, with an extention of .conf, under the /etc/zm/conf.d
# folder, containing your desired modifications.
#

# Path to installed data directory, used mostly for finding DB upgrade scripts
ZM_PATH_DATA=/usr/share/zoneminder

# Path to ZoneMinder binaries
ZM_PATH_BIN=/usr/bin

# Path to ZoneMinder libraries (none at present, for future use)
ZM_PATH_LIB=/usr/lib/x86_64-linux-gnu

# Path to ZoneMinder configuration (this file only at present)
ZM_PATH_CONF=/etc/zm

# Path to ZoneMinder web files
ZM_PATH_WEB=/usr/share/zoneminder/www

# Path to ZoneMinder cgi files
ZM_PATH_CGI=/usr/lib/zoneminder/cgi-bin

# Username and group that web daemon (httpd/apache) runs as
ZM_WEB_USER=www-data
ZM_WEB_GROUP=www-data

# ZoneMinder database type: so far only mysql is supported
ZM_DB_TYPE=mysql

# ZoneMinder database hostname or ip address and optionally port or unix socket
# Acceptable formats include hostname[:port], ip_address[:port], or localhost:unix_socket
ZM_DB_HOST=127.0.0.1:3306

# ZoneMinder database name
ZM_DB_NAME=zoneminder

# ZoneMinder database user
ZM_DB_USER=zoneminder

# ZoneMinder database password
ZM_DB_PASS=my_password

# SSL CA certificate for ZoneMinder database
ZM_DB_SSL_CA_CERT=

# SSL client key for ZoneMinder database
ZM_DB_SSL_CLIENT_KEY=

# SSL client cert for ZoneMinder database
ZM_DB_SSL_CLIENT_CERT=

# Do NOT set ZM_SERVER_HOST if you are not using Multi-Server
# You have been warned
#
# The name specified here must have a corresponding entry
# in the Servers tab under Options
ZM_SERVER_HOST=
docker-compose.yml

Code: Select all

version: '3.7'

services:

  mariadb:
    image: mariadb
    container_name: mariadb
    environment:
      - TZ=Europe/Paris
      - MYSQL_ROOT_PASSWORD=my_password
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /etc/timezone:/etc/timezone:ro
      - /srv/mysql:/var/lib/mysql
      - /tmp/docker:/tmp
    network_mode: host
    restart: always

  zoneminder:
    container_name: zoneminder
    privileged: true
    build:
      context: .
      dockerfile: Dockerfile-zoneminder
      network: host
      args:
        MYSQL_USER: zoneminder
        MYSQL_PASSWORD: my_password
        MYSQL_ROOT_HOST: 127.0.0.1:3306
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /etc/timezone:/etc/timezone:ro
      - /srv/zoneminder:/config
      - /srv/zoneminder/data:/var/cache/zoneminder
      - /tmp/docker:/tmp
    environment:
      - TZ=Europe/Paris
      - SHMEM="50%"
      - PUID=33
      - PGID=33
      - INSTALL_HOOK="0"
      - INSTALL_FACE="0"
      - INSTALL_TINY_YOLO="0"
      - INSTALL_YOLO="0"
    network_mode: host
    restart: always
    depends_on:
      - mariadb
Dockerfile-zoneminder

Code: Select all

FROM dlandon/baseimage

ENV PHP_VERS="7.1"
ENV ZM_VERS="1.32"
ENV ZMEVENT_VERS="4.6"

COPY init/ /etc/my_init.d/
COPY defaults/ /root/
COPY zmeventnotification /root/zmeventnotification/

RUN add-apt-repository -y ppa:iconnor/zoneminder-$ZM_VERS && \
    add-apt-repository ppa:ondrej/php && \
    add-apt-repository ppa:ondrej/apache2 && \
    apt-get update && \
    apt-get -y upgrade -o Dpkg::Options::="--force-confold" && \
    apt-get -y dist-upgrade -o Dpkg::Options::="--force-confold" && \
    apt-get -y install apache2 ssmtp mailutils net-tools libav-tools wget sudo make \
    php$PHP_VERS php$PHP_VERS-fpm libapache2-mod-php$PHP_VERS php$PHP_VERS-mysql php$PHP_VERS-gd \
    libcrypt-mysql-perl libyaml-perl libjson-perl && \
    apt-get -y install --no-install-recommends libvlc-dev libvlccore-dev vlc nano zoneminder && \
    adduser www-data video && \
    a2enmod php$PHP_VERS proxy_fcgi ssl rewrite expires headers && \
    a2enconf php$PHP_VERS-fpm zoneminder && \
    echo "extension=apcu.so" > /etc/php/$PHP_VERS/mods-available/apcu.ini && \
    echo "extension=mcrypt.so" > /etc/php/$PHP_VERS/mods-available/mcrypt.ini && \
    perl -MCPAN -e "force install Net::WebSocket::Server" && \
    perl -MCPAN -e "force install LWP::Protocol::https" && \
    perl -MCPAN -e "force install Config::IniFiles" && \
    perl -MCPAN -e "force install Net::MQTT::Simple" && \
    perl -MCPAN -e "force install Net::MQTT::Simple::Auth"

RUN chown -R www-data:www-data /usr/share/zoneminder/ && \
    echo "ServerName localhost" >> /etc/apache2/apache2.conf && \
    sed -i "s|^;date.timezone =.*|date.timezone = ${TZ}|" /etc/php/$PHP_VERS/apache2/php.ini && \
    sed -i "s|Listen 80|Listen 81|" /etc/apache2/ports.conf && \
    sed -i "s|Listen 443|Listen 444|" /etc/apache2/ports.conf && \
    sed -i "s|80|81|" /etc/apache2/sites-available/000-default.conf && \
    mv /root/zoneminder /etc/init.d/zoneminder && \
    chmod +x /etc/init.d/zoneminder && \
    service apache2 restart

ARG MYSQL_USER
ARG MYSQL_PASSWORD
ARG MYSQL_ROOT_HOST

RUN sed -i "s|ZM_DB_HOST=localhost|ZM_DB_HOST=$MYSQL_ROOT_HOST|" /etc/zm/zm.conf && \
    sed -i "s|ZM_DB_USER=zmuser|ZM_DB_USER=$MYSQL_USER|" /etc/zm/zm.conf && \
    sed -i "s|ZM_DB_NAME=zm|ZM_DB_NAME=$MYSQL_USER|" /etc/zm/zm.conf && \
    sed -i "s|ZM_DB_PASS=zmpass|ZM_DB_PASS=$MYSQL_PASSWORD|" /etc/zm/zm.conf && \
    service zoneminder start && \
    systemd-tmpfiles --create zoneminder.conf && \
    mv /root/default-ssl.conf /etc/apache2/sites-available/default-ssl.conf && \
    sed -i "s|443|444|" /etc/apache2/sites-available/default-ssl.conf && \
    mkdir /etc/apache2/ssl/ && \
    mkdir -p /var/lib/zmeventnotification/images && \
    chown -R www-data:www-data /var/lib/zmeventnotification/ && \
    chmod -R +x /etc/my_init.d/ && \
    cp -p /etc/zm/zm.conf /root/zm.conf && \
    echo "#!/bin/sh\n\n/usr/bin/zmaudit.pl -f" >> /etc/cron.weekly/zmaudit && \
    chmod +x /etc/cron.weekly/zmaudit && \
    apt-get -y remove make && \
    apt-get -y clean && \
    apt-get -y autoremove && \
    rm -rf /tmp/* /var/tmp/*
User avatar
bkjaya1952
Posts: 282
Joined: Sat Aug 25, 2018 3:24 pm
Location: Sri Lanka

Re: ERR [undef] Can't insert log entry in Docker Container

Post by bkjaya1952 »

I have pushed a Zoneminder-master , v1.33.16. docker image with MSMTP repository to the Docker Hub . Please see the Dockerfile that I have used.

https://hub.docker.com/r/bkjaya1952/doc ... der-master

https://bkjaya.wordpress.com/2020/01/12 ... an-ermine/
Post Reply