diff --git a/infinite-silence-stream.service b/infinite-silence-stream.service new file mode 100644 index 0000000..ed75aa3 --- /dev/null +++ b/infinite-silence-stream.service @@ -0,0 +1,11 @@ +[Unit] +Description=Infinite silence stream +Requires=jackd.service + +[Service] +ExecStart=/usr/bin/ffmpeg -ac 1 -f jack -i infinite-silence -c:a libmp3lame -b:a 192k -ac 1 -content_type 'audio/mpeg' -f mp3 icecast://source:iamapassword@localhost:8016/silence +Restart=on-failure + +[Install] +Also=jackd.service +WantedBy=default.target diff --git a/infinite-silence.service b/infinite-silence.service new file mode 100644 index 0000000..d86e427 --- /dev/null +++ b/infinite-silence.service @@ -0,0 +1,13 @@ +[Unit] +Description=Complete silence, always +Requires=jackd.service +Requires=infinite-silence-stream.service + +[Service] +ExecStart=/usr/bin/python3 /home/ash/silence/infinite-silence.py infinite-silence 5 30 /home/ash/silence/sfx.mp3 +Restart=on-failure + +[Install] +Also=jackd.service +Also=infinite-silence-stream.service +WantedBy=default.target diff --git a/jackd.service b/jackd.service new file mode 100644 index 0000000..36ba9bd --- /dev/null +++ b/jackd.service @@ -0,0 +1,9 @@ +[Unit] +Description=jackd + +[Service] +ExecStart=/usr/bin/jackd -t5000 -r -dalsa -r48000 -n3 +Restart=no-failure + +[Install] +WantedBy=default.target