Skip to content

reneManqueros/WatchYourLAN

 
 

Repository files navigation


WatchYourLAN

Docker Docker Image Size (latest semver)

Lightweight network IP scanner with web GUI
https://github.com/reneManqueros/WatchYourLAN

Screenshot_v0.6

Quick start

Replace $YOURTIMEZONE with correct time zone and $YOURIFACE with network interface you want to scan. Network mode must be host.

docker run --name wyl \
	-e "IFACE=$YOURIFACE" \
	-e "TZ=$YOURTIMEZONE" \
	--network="host" \
    renemanqueros/watchyourlan

Set $DOCKERDATAPATH for container to save data:

docker run --name wyl \
	-e "IFACE=$YOURIFACE" \
	-e "TZ=$YOURTIMEZONE" \
	--network="host" \
	-v $DOCKERDATAPATH/wyl:/data \
    renemanqueros/watchyourlan

Web GUI should be at http://localhost:8840

Config

Configuration can be done through config file or environment variables

Variable Description Default
IFACE Interface to scan. Could be one or more, separated by space. Currently docker0 is not allowed, as arp-scan wouldn't work with it correctly enp1s0
DBPATH Path to Database /data/db.sqlite
DBPROVIDER DBMS to use (sqlite, mongodb) sqlite
GUIIP Address for web GUI localhost (127.0.0.1)
GUIPORT Port for web GUI 8840
GUIAUTH Basic auth credentials for web GUI, e.g.: GUIAUTH=user:pass (empty - no auth)
TIMEOUT Time between scans (seconds) 60 (1 minute)
SHOUTRRR_URL Url to any notification service supported by Shoutrrr (gotify, email, telegram and others) ""
THEME Any theme name from https://bootswatch.com in lowcase solar
MONGODBCONNECTIONURI Connection string to MongoDB (empty)
MONGODBCOLLECTION MongoDB Collection (empty)
MONGODBDATABASE MongoDB Database (empty)

Config file

Config file path is /data/config. All variables could be set there. Example:

IFACE="enp2s0 wg0"
DBPATH="/data/hosts.db"
GUIIP="192.168.2.1"     		# To access from LAN
GUIPORT="8840"
TIMEOUT="300"           		# 5 minutes
SHOUTRRR_URL="gotify://192.168.2.1:8083/AwQqpAae.rrl5Ob/?title=Unknown host detected&DisableTLS=yes"	# Url to notify
THEME="darkly"

Releases

WatchYourLAN uses goreleaser to generate multi-platform releases.

Generate a token here: https://github.com/settings/tokens/new

Add as an environment variable:

export GITHUB_TOKEN=<TOKEN GOES HERE>

Run goreleaser:

curl -sfL https://goreleaser.com/static/run | bash -s -- release

Thanks

About

Lightweight network IP scanner with web GUI

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 59.7%
  • HTML 36.5%
  • Makefile 2.8%
  • Dockerfile 1.0%