Phoenix site for managing audio to play when a certain IP address connects to the local network.
Go to file
silentsilas c6a5b1a3ab
update dependencies, add recommended extensions
2024-07-28 13:04:27 -04:00
.vscode update dependencies, add recommended extensions 2024-07-28 13:04:27 -04:00
assets switch mp3 to tts, add genserver to app supervisor tree that periodically checks for newly connected devices and plays their associated tts message 2024-07-17 18:20:05 -04:00
config switch mp3 to tts, add genserver to app supervisor tree that periodically checks for newly connected devices and plays their associated tts message 2024-07-17 18:20:05 -04:00
lib switch mp3 to tts, add genserver to app supervisor tree that periodically checks for newly connected devices and plays their associated tts message 2024-07-17 18:20:05 -04:00
priv switch mp3 to tts, add genserver to app supervisor tree that periodically checks for newly connected devices and plays their associated tts message 2024-07-17 18:20:05 -04:00
test switch mp3 to tts, add genserver to app supervisor tree that periodically checks for newly connected devices and plays their associated tts message 2024-07-17 18:20:05 -04:00
.env init commit 2024-07-13 15:12:19 -04:00
.formatter.exs init commit 2024-07-13 15:12:19 -04:00
.gitignore init commit 2024-07-13 15:12:19 -04:00
.tool-versions init commit 2024-07-13 15:12:19 -04:00
README.md Update readme with prerequisites 2024-07-17 18:35:16 -04:00
docker-compose.yml init commit 2024-07-13 15:12:19 -04:00
mix.exs init commit 2024-07-13 15:12:19 -04:00
mix.lock update dependencies, add recommended extensions 2024-07-28 13:04:27 -04:00

README.md

Here I Am

Description

Here I Am is a Phoenix application that monitors devices connecting to your local network and plays a text-to-speech message using espeak when a new device is detected. The application uses arp-scan to identify devices on the network.

Prerequisites

Erlang and Elixir

In this project, these are managed by asdf. You will need to install 'https://github.com/asdf-vm/asdf, ['https://github.com/asdf-vm/asdf-erlang](ASDF Erlang), and ['https://github.com/asdf-vm/asdf-elixir](ASDF Elixir). Be sure to read on what the Erlang / Elixir ASDF prerequisites are before installing the plugins.

Alternatively, you can install erlang/elixir without a version manager but that won't be covered here.

Installing espeak

Install espeak on your system:

# On Debian/Ubuntu-based systems
sudo apt-get install espeak

# Fedora/RHEL
sudo dnf install espeak

Installing arp-scan

Install arp-scan on your system:

# On Debian/Ubuntu-based systems
sudo apt-get install arp-scan

# Fedora/RHEL
sudo dnf install arp-scan

Configuring sudo for arp-scan

To allow arp-scan to run without a password, edit the sudoers file:

sudo visudo

Add the following line to allow your user to run arp-scan without a password (replace yourusername with your actual username):

yourusername ALL=(ALL) NOPASSWD: /usr/sbin/arp-scan

Your arp-scan installation may not be in /usr/sbin/arp-scan. Please run whereis arp-scan to find the correct path for the above config.

Setup

To start your Phoenix server:

  • Run mix setup to install and setup dependencies
  • Start Phoenix endpoint with mix phx.server or inside IEx with iex -S mix phx.server

Now you can visit localhost:4000 from your browser.

Ready to run in production? Please check the deployment guides.