Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion hassio-access-point/config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: Hass.io Access Point
version: 0.5.4
version: 0.5.4-1
slug: hassio-access-point
description: Create a WiFi access point to directly connect devices to Home Assistant
arch: [armhf, armv7, aarch64, amd64, i386]
Expand Down Expand Up @@ -32,6 +32,7 @@ options:
client_internet_access: false
client_dns_override: []
dnsmasq_config_override: []
custom_commands: []
schema:
ssid: match(^.{2,32}$)
wpa_passphrase: password
Expand All @@ -57,3 +58,5 @@ schema:
- match(^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$)
dnsmasq_config_override:
- str?
custom_commands:
- str?
6 changes: 6 additions & 0 deletions hassio-access-point/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,12 @@ if $(bashio::config.true "dhcp"); then
dnsmasq -C /dnsmasq.conf
fi

while IFS= read -r cmd; do
[ -z "$cmd" ] && continue
echo "Running: $cmd"
eval "$cmd"
done <<< "$(bashio::config 'custom_commands')"

logger "## Starting hostapd daemon" 1
# If debug level is greater than 1, start hostapd in debug mode
if [ $DEBUG -gt 1 ]; then
Expand Down
4 changes: 4 additions & 0 deletions hassio-access-point/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@
"dnsmasq_config_override": {
"name": "DNSMASQ Custom Configuration",
"description": "A list of options to append to the `dnsmasq.conf` file. Don't touch if you don't know what you're doing."
},
"custom_commands": {
"name": "Custom Commands",
"description": "A list of commands that will be executed before `hostapd` is started. Don't touch if you don't know what you're doing."
}
}
}