mirror of
https://github.com/vimagick/dockerfiles
synced 2024-06-16 03:48:44 +00:00
update zoneminder
This commit is contained in:
parent
cacfadb57b
commit
7c034993e9
@ -139,7 +139,7 @@ A collection of delicious docker recipes.
|
|||||||
- [x] phpvirtualbox-arm
|
- [x] phpvirtualbox-arm
|
||||||
- [x] piwik
|
- [x] piwik
|
||||||
- [x] revive
|
- [x] revive
|
||||||
- [x] zoneminder
|
- [x] zoneminder :+1:
|
||||||
|
|
||||||
## Builder
|
## Builder
|
||||||
|
|
||||||
|
@ -85,7 +85,6 @@ $ docker-compose logs service
|
|||||||
# /etc/ngrok/ngrok.yml
|
# /etc/ngrok/ngrok.yml
|
||||||
authtoken: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
authtoken: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
||||||
console_ui: false
|
console_ui: false
|
||||||
log: stdout
|
|
||||||
region: ap
|
region: ap
|
||||||
web_addr: 0.0.0.0:4040
|
web_addr: 0.0.0.0:4040
|
||||||
tunnels:
|
tunnels:
|
||||||
@ -103,11 +102,12 @@ tunnels:
|
|||||||
```ini
|
```ini
|
||||||
# /etc/systemd/system/ngrok.service
|
# /etc/systemd/system/ngrok.service
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=Ngrok Daemon
|
Description=Secure Tunnels To Localhost
|
||||||
|
Documentation=https://ngrok.com/docs
|
||||||
After=network.target
|
After=network.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
ExecStart=/usr/bin/ngrok start --config /etc/ngrok/ngrok.yml --all
|
ExecStart=/usr/bin/ngrok start --config /etc/ngrok/ngrok.yml --log stdout --all
|
||||||
RestartSec=10
|
RestartSec=10
|
||||||
Restart=always
|
Restart=always
|
||||||
|
|
||||||
|
@ -26,6 +26,8 @@ COPY nginx.conf /etc/nginx/sites-available/default
|
|||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|
||||||
CMD set -xe \
|
CMD set -xe \
|
||||||
|
&& mkdir -p /var/run/zm \
|
||||||
|
&& chown www-data:www-data /var/run/zm \
|
||||||
&& /etc/init.d/fcgiwrap start \
|
&& /etc/init.d/fcgiwrap start \
|
||||||
&& /etc/init.d/php5-fpm start \
|
&& /etc/init.d/php5-fpm start \
|
||||||
&& nginx -g 'daemon off;'
|
&& nginx -g 'daemon off;'
|
||||||
|
@ -22,15 +22,35 @@ zoneminder:
|
|||||||
mysql:
|
mysql:
|
||||||
image: mysql
|
image: mysql
|
||||||
volumes:
|
volumes:
|
||||||
- ./sql:/docker-entrypoint-initdb.d
|
- ./mysql/my.cnf:/etc/mysql/conf.d/my.cnf
|
||||||
|
- ./mysql:/docker-entrypoint-initdb.d
|
||||||
|
- /usr/share/zoneinfo/Asia/Shanghai:/etc/localtime
|
||||||
environment:
|
environment:
|
||||||
- MYSQL_ROOT_PASSWORD=root
|
- MYSQL_ROOT_PASSWORD=root
|
||||||
restart: always
|
restart: always
|
||||||
```
|
```
|
||||||
|
|
||||||
|
> - `timezone = Asia/Shanghai` was hard-coded in Dockerfile.
|
||||||
|
> - Make sure two containers have the same timezone.
|
||||||
|
|
||||||
|
## up and running
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ docker-compose up -d
|
||||||
|
```
|
||||||
|
|
||||||
|
- Open <http://localhost:8080/zm/>
|
||||||
|
- Add New Monitor
|
||||||
|
- Click Presets
|
||||||
|
- Change Source
|
||||||
|
- Save
|
||||||
|
- Run State: Stopped -> Running
|
||||||
|
|
||||||
## references
|
## references
|
||||||
|
|
||||||
- <https://wiki.zoneminder.com/Ubuntu_Server_16.04_64-bit_with_Zoneminder_1.29.0_the_easy_way>
|
- <https://wiki.zoneminder.com/Ubuntu_Server_16.04_64-bit_with_Zoneminder_1.29.0_the_easy_way>
|
||||||
- <https://chiralsoftware.com/content/zoneminder-nginx-yes-it-works>
|
- <https://chiralsoftware.com/content/zoneminder-nginx-yes-it-works>
|
||||||
|
- <https://forums.zoneminder.com/viewtopic.php?p=55482>
|
||||||
|
- <https://dev.mysql.com/doc/refman/5.7/en/option-files.html>
|
||||||
|
|
||||||
[1]: https://www.zoneminder.com/
|
[1]: https://www.zoneminder.com/
|
||||||
|
@ -9,7 +9,9 @@ zoneminder:
|
|||||||
mysql:
|
mysql:
|
||||||
image: mysql
|
image: mysql
|
||||||
volumes:
|
volumes:
|
||||||
- ./sql:/docker-entrypoint-initdb.d
|
- ./mysql/my.cnf:/etc/mysql/conf.d/my.cnf
|
||||||
|
- ./mysql:/docker-entrypoint-initdb.d
|
||||||
|
- /usr/share/zoneinfo/Asia/Shanghai:/etc/localtime
|
||||||
environment:
|
environment:
|
||||||
- MYSQL_ROOT_PASSWORD=root
|
- MYSQL_ROOT_PASSWORD=root
|
||||||
restart: always
|
restart: always
|
||||||
|
2
zoneminder/mysql/my.cnf
Normal file
2
zoneminder/mysql/my.cnf
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
[mysqld]
|
||||||
|
sql_mode = NO_ENGINE_SUBSTITUTION
|
@ -13,12 +13,9 @@ server {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
location /zm/cgi-bin/ {
|
location = /zm/cgi-bin/nph-zms {
|
||||||
alias /usr/lib/zoneminder/cgi-bin/;
|
include fastcgi_params;
|
||||||
location ~ \.php$ {
|
fastcgi_param SCRIPT_FILENAME /usr/lib/zoneminder/cgi-bin/nph-zms;
|
||||||
include fastcgi_params;
|
fastcgi_pass unix:/var/run/fcgiwrap.socket;
|
||||||
fastcgi_param SCRIPT_FILENAME $request_filename;
|
|
||||||
fastcgi_pass unix:/var/run/fcgiwrap.socket;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user