summaryrefslogtreecommitdiffstats
path: root/lass/2configs
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2022-08-02 14:34:22 +0200
committermakefu <github@syntax-fehler.de>2022-08-02 14:34:22 +0200
commit739fad41da87d206f76bc3db9861d8b2bd0a5639 (patch)
tree023f294d5ba55b93905772eec90a3ebbe3667528 /lass/2configs
parentbebf0baf031fca08fde11cc7f840fc885737f5b7 (diff)
parentb3694198eaac7ffd13640c64bc3e3af27e40389b (diff)
Merge remote-tracking branch 'lass/master'
Diffstat (limited to 'lass/2configs')
-rw-r--r--lass/2configs/fysiirc.nix9
-rw-r--r--lass/2configs/radio/default.nix2
-rw-r--r--lass/2configs/radio/weather_for_ips.py6
-rw-r--r--lass/2configs/websites/domsen.nix2
4 files changed, 9 insertions, 10 deletions
diff --git a/lass/2configs/fysiirc.nix b/lass/2configs/fysiirc.nix
index e12eda42e..809298df4 100644
--- a/lass/2configs/fysiirc.nix
+++ b/lass/2configs/fysiirc.nix
@@ -10,8 +10,7 @@
${write_to_irc} "$(echo "$INPUT" | jq -r '
"\(.action): " +
"[\(.issue.title // .pull_request.title)] " +
- "\(.comment.html_url // .issue.html_url // .pull_request.html_url) " +
- "by \(.comment.user.login // .issue.user.login // .pull_request.user.login)"
+ "\(.comment.html_url // .issue.html_url // .pull_request.html_url) "
')"
fi
'';
@@ -58,16 +57,16 @@ in {
case "$Method $Request_URI" in
"POST /")
payload=$(head -c "$req_content_length")
- echo "$payload" >&2
+ raw=$(printf '%s' "$payload" | ${pkgs.curl}/bin/curl --data-binary @- http://p.krebsco.de | tail -1)
payload2=$payload
- payload2=$(echo "$payload" | tr '\n' ' ' | tr -d '\r')
+ payload2=$(printf '%s' "$payload" | tr '\n' ' ' | tr -d '\r')
if [ "$payload" != "$payload2" ]; then
echo "payload has been mangled" >&2
else
echo "payload not mangled" >&2
fi
- echo "$payload2" > /tmp/last_fysi_payload
echo "$payload2" | ${format-github-message}/bin/format-github-message
+ ${write_to_irc} "$raw"
printf 'HTTP/1.1 200 OK\r\n'
printf 'Connection: close\r\n'
printf '\r\n'
diff --git a/lass/2configs/radio/default.nix b/lass/2configs/radio/default.nix
index b8d958865..2f503eae9 100644
--- a/lass/2configs/radio/default.nix
+++ b/lass/2configs/radio/default.nix
@@ -168,7 +168,7 @@ in {
output.icecast(mount = '/music.mp3', password = 'hackme', %mp3.vbr(), source)
output.icecast(mount = '/music.opus', password = 'hackme', %opus(bitrate = 96), source)
- extra_input = audio_to_stereo(input.harbor("live", port=1338))
+ extra_input = amplify(1.4, audio_to_stereo(input.harbor("live", port=1338)))
o = smooth_add(normal = source, special = extra_input)
output.icecast(mount = '/radio.ogg', password = 'hackme', %vorbis(quality = 1), o)
diff --git a/lass/2configs/radio/weather_for_ips.py b/lass/2configs/radio/weather_for_ips.py
index f7cc2dace..587cc1f28 100644
--- a/lass/2configs/radio/weather_for_ips.py
+++ b/lass/2configs/radio/weather_for_ips.py
@@ -25,9 +25,9 @@ for ip in fileinput.input():
output.append(
f'Weather report for {location.city.name}, {location.country.name}. '
f'Currently it is {weather["current"]["weather"][0]["description"]} outside '
- f'with a temperature of {weather["current"]["temp"]} degrees, '
- f'and a wind speed of {weather["current"]["wind_speed"]} meters per second. '
- f'The probability of precipitation is {weather["hourly"][0]["pop"] * 100} percent. '
+ f'with a temperature of {weather["current"]["temp"]:.1f} degrees, '
+ f'and a wind speed of {weather["current"]["wind_speed"]:.1f} meters per second. '
+ f'The probability of precipitation is {weather["hourly"][0]["pop"] * 100:.0f} percent. '
)
print('\n'.join(output))
diff --git a/lass/2configs/websites/domsen.nix b/lass/2configs/websites/domsen.nix
index fe4d78a3b..90a0a5a72 100644
--- a/lass/2configs/websites/domsen.nix
+++ b/lass/2configs/websites/domsen.nix
@@ -104,7 +104,7 @@ in {
services.nextcloud = {
enable = true;
hostName = "o.xanf.org";
- package = pkgs.nextcloud23;
+ package = pkgs.nextcloud24;
config = {
adminpassFile = "/run/nextcloud.pw";
overwriteProtocol = "https";