Skip to content

Commit 34cc4aa

Browse files
committed
feat: add HTTP port 4431 and informative startup log
- Add port 80/tcp → 4431 mapping so HTTP redirects users to HTTPS (browse http://homeassistant.local:4431 → redirected to HTTPS) - Log clear URL instructions on startup so users know how to connect - Bump version to 0.2.7
1 parent d91c789 commit 34cc4aa

2 files changed

Lines changed: 15 additions & 3 deletions

File tree

meshcentral/config.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "MeshCentral",
3-
"version": "0.2.6",
3+
"version": "0.2.7",
44
"slug": "meshcentral",
55
"description": "Self-hosted remote device management — monitor and control your PCs from Home Assistant",
66
"url": "https://github.com/andlo/ha-meshcentral-addon",
@@ -10,10 +10,12 @@
1010
"init": false,
1111
"ports": {
1212
"443/tcp": 4430,
13+
"80/tcp": 4431,
1314
"4433/tcp": 4433
1415
},
1516
"ports_description": {
1617
"443/tcp": "MeshCentral web interface (HTTPS)",
18+
"80/tcp": "MeshCentral HTTP redirect → HTTPS",
1719
"4433/tcp": "Intel AMT / MPS port"
1820
},
1921
"options": {

meshcentral/run.sh

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,6 @@ fi
4545

4646
# Ports — always explicit so there's no ambiguity
4747
SETTINGS=$(echo "$SETTINGS" | jq '. + {port: 443, redirPort: 80, mpsPort: 4433}')
48-
49-
# TLS offload (false by default — only true if user has a reverse proxy)
5048
SETTINGS=$(echo "$SETTINGS" | jq --argjson v "$TLS_OFFLOAD" '. + {tlsOffload: $v}')
5149

5250
# Trusted proxy (optional)
@@ -153,6 +151,18 @@ fi
153151

154152
# ── Start MeshCentral ─────────────────────────────────────────────────────────
155153

154+
HA_IP=$(bashio::info.ip_address 2>/dev/null || echo "homeassistant.local")
155+
HTTPS_PORT=$(bashio::addon.port "443/tcp" 2>/dev/null || echo "4430")
156+
HTTP_PORT=$(bashio::addon.port "80/tcp" 2>/dev/null || echo "4431")
157+
158+
bashio::log.info "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
159+
bashio::log.info " MeshCentral is starting..."
160+
bashio::log.info " Open in browser (accept certificate warning):"
161+
bashio::log.info " https://${HA_IP}:${HTTPS_PORT}"
162+
bashio::log.info " Or via HTTP redirect:"
163+
bashio::log.info " http://${HA_IP}:${HTTP_PORT}"
164+
bashio::log.info "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
165+
156166
bashio::log.info "Starting MeshCentral node process..."
157167
exec node /opt/meshcentral/node_modules/meshcentral \
158168
--datapath "${DATA_PATH}" \

0 commit comments

Comments
 (0)