Skip to content

Commit fe07cd5

Browse files
authoredOct 4, 2024
Merge pull request #259 from DanielGallo:dev-v3
Updates for WebDashboard
2 parents 6abfa43 + 8827830 commit fe07cd5

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed
 

‎Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ RUN apk add redis
1212
RUN apk add nginx
1313

1414
RUN mkdir -p /run/nginx
15-
RUN npm install -g serve
15+
RUN npm install -g http-server
1616

1717
# set the working directory in the container
1818
WORKDIR /app
@@ -43,6 +43,6 @@ COPY redis.conf redis.conf
4343
COPY settings.json ./settings.json
4444
COPY ingress/ ./ingress
4545

46-
EXPOSE 1883 6379 8099
46+
EXPOSE 1883 3000 6379 8099
4747

4848
CMD ["python3", "/app/startup.py"]

‎WebDashboard

‎startup.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -625,7 +625,7 @@ def findinv(networks):
625625
outp.write("}")
626626
WDPORT=int(setts['Web_Dash_Port'])
627627
logger.info ("Serving Web Dashboard from port "+str(WDPORT))
628-
command=shlex.split("/usr/bin/node /usr/local/bin/serve -p "+ str(WDPORT))
628+
command=shlex.split("/usr/bin/node /usr/local/bin/http-server -p "+ str(WDPORT))
629629
webDash=subprocess.Popen(command)
630630

631631

@@ -678,7 +678,7 @@ def findinv(networks):
678678
os.chdir("/app/WebDashboard")
679679
WDPORT = int(setts['Web_Dash_Port'])
680680
logger.info("Serving Web Dashboard from port " + str(WDPORT))
681-
command = shlex.split("/usr/bin/node /usr/local/bin/serve -p " + str(WDPORT))
681+
command = shlex.split("/usr/bin/node /usr/local/bin/http-server -p " + str(WDPORT))
682682
webDash = subprocess.Popen(command)
683683

684684
if setts['MQTT_Address']=="127.0.0.1":

0 commit comments

Comments
 (0)
Please sign in to comment.