first commit

This commit is contained in:
2022-12-27 21:59:06 +01:00
commit 7ae0b00241
29 changed files with 1157 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
FROM ubuntu:22.04
RUN apt-get update && apt-get -y upgrade
RUN apt-get -y install avahi-utils libnss-mdns dos2unix
ADD entrypoint.sh /opt/entrypoint.sh
RUN dos2unix /opt/entrypoint.sh ; chmod +x /opt/entrypoint.sh
CMD ["sh", "/opt/entrypoint.sh"]

View File

@@ -0,0 +1,15 @@
#!/bin/bash
service dbus start
service avahi-daemon start
dos2unix /opt/config/names.csv
while read LINE; do
PUBLISH_HOSTNAME=$(echo $LINE | cut -d ";" -f 1)
PUBLISH_IP=$(echo $LINE | cut -d ";" -f 2)
echo "$PUBLISH_HOSTNAME - $PUBLISH_IP"
/usr/bin/avahi-publish -a -R $PUBLISH_HOSTNAME $PUBLISH_IP &
done < /opt/config/names.csv
tail -f /dev/null

View File

@@ -0,0 +1,3 @@
opensearch.local;192.168.57.2
traefik.local;192.168.57.2
grafana.local;192.168.57.2
1 opensearch.local 192.168.57.2
2 traefik.local 192.168.57.2
3 grafana.local 192.168.57.2