update audiometer
This commit is contained in:
parent
ea75de4724
commit
821b7b518d
5 changed files with 27 additions and 7 deletions
|
@ -2,18 +2,18 @@
|
|||
- name: Make sure stream_input_url is set
|
||||
ansible.builtin.fail:
|
||||
msg: "Please define stream_input_url"
|
||||
when: not stream_input_url | bool
|
||||
when: stream_input_url == false
|
||||
|
||||
- name: Make sure stream_name is set
|
||||
ansible.builtin.fail:
|
||||
msg: "Please define stream_name"
|
||||
when: not stream_name | bool
|
||||
when: stream_name == false
|
||||
|
||||
- name: Create systemd service
|
||||
become: true
|
||||
ansible.builtin.template:
|
||||
src: 'templates/audiometer.service.j2'
|
||||
dest: '/lib/systemd/system/audiometer.service.j2'
|
||||
dest: '/lib/systemd/system/audiometer.service'
|
||||
mode: 0640
|
||||
owner: root
|
||||
group: root
|
||||
|
@ -29,3 +29,4 @@
|
|||
mode: 0655
|
||||
owner: video
|
||||
group: video
|
||||
notify: Systemctl restart audiometer.service
|
||||
|
|
|
@ -1,15 +1,17 @@
|
|||
{{ ansible_managed | comment }}
|
||||
|
||||
[Unit]
|
||||
Description=create audiometer for {{ inventory_hstname }}
|
||||
Description=create audiometer for {{ inventory_hostname }}
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Restart=always
|
||||
User=video
|
||||
ExecStart=/opt/audiometer.sh
|
||||
ExecStart=/bin/sh /opt/audiometer.sh
|
||||
ExecReload=/bin/kill -HUP $MAINPID
|
||||
StartLimitBurst=2
|
||||
StartLimitInterval=8
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
ffmpeg -listen 1 -i {{ stream_input_url }} \
|
||||
ffmpeg -i {{ stream_input_url }} \
|
||||
-nostats \
|
||||
-loglevel repeat+level+info \
|
||||
-filter_complex \
|
||||
|
@ -8,7 +8,7 @@ ffmpeg -listen 1 -i {{ stream_input_url }} \
|
|||
[full_mix]framerate=fps=25[out]; \
|
||||
[orig_scaled]drawtext=fontfile=/srv/www/{{ inventory_hostname }}/opensans.ttf:text={{ stream_name }}:fontcolor=white:fontsize=100:box=1:boxcolor=black@0.5:boxborderw=5:x=(w-text_w)/2:y=(h-text_h)/1.5[preview_overlay];\
|
||||
[0:a:0]ebur128=video=1:size=640x480:meter=9:target=-16:gauge=shortterm[native][native_a]; [native_a]anullsink; \
|
||||
[native]drawtext=fontfile=/srv/www/{{ inventory_hostname }}/opensans.ttf:text=native:fontcolor=white:fontsize=60:box=1:boxcolor=black@0.5:boxborderw=5:x=(w-text_w)/2:y=(h-text_h)/1.5[native_overlay];\
|
||||
[native]drawtext=fontfile=/srv/www/{{ inventory_hostname }}/opensans.ttf:text=audio:fontcolor=white:fontsize=60:box=1:boxcolor=black@0.5:boxborderw=5:x=(w-text_w)/2:y=(h-text_h)/1.5[native_overlay];\
|
||||
[0:a:0]showvolume=r=50:w=640:h=60:b=0:ds=log:dm=1.0[native_vu]; \
|
||||
[preview_overlay][native_vu][native_overlay]vstack=inputs=3[full_mix] " \
|
||||
-map "[out]" \
|
||||
|
|
17
templates/files/nginx/sites/test.winkekatze.tv_tls.conf
Normal file
17
templates/files/nginx/sites/test.winkekatze.tv_tls.conf
Normal file
|
@ -0,0 +1,17 @@
|
|||
server {
|
||||
listen 443 ssl http2;
|
||||
listen [::]:443 ssl http2;
|
||||
|
||||
server_name test.winkekatze.tv;
|
||||
|
||||
include snippets/tls_parameters_{{ site.name }}.snippet.conf;
|
||||
include snippets/tls_certificate_{{ site.name }}.snippet.conf;
|
||||
include snippets/logging_{{ site.name }}.snippet.conf;
|
||||
|
||||
root /srv/www/test.winkekatze.tv;
|
||||
|
||||
location / {
|
||||
charset utf-8;
|
||||
try_files $uri $uri/ =404;
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue