1
0
mirror of https://github.com/Artemis-RGB/Artemis synced 2025-12-13 05:48:35 +00:00

Web Server Service - Changed listening URL to wildcard

this should make the web server work for both ipv4 and ipv6
This commit is contained in:
Diogo Trindade 2021-02-24 21:39:46 +00:00
parent 8795500991
commit 291eabd20e

View File

@ -42,7 +42,7 @@ namespace Artemis.Core.Services
Server?.Dispose(); Server?.Dispose();
Server = null; Server = null;
string url = $"http://localhost:{_webServerPortSetting.Value}/"; string url = $"http://*:{_webServerPortSetting.Value}/";
WebApiModule apiModule = new("/api/", JsonNetSerializer); WebApiModule apiModule = new("/api/", JsonNetSerializer);
PluginsModule.ServerUrl = url; PluginsModule.ServerUrl = url;
WebServer server = new WebServer(o => o.WithUrlPrefix(url).WithMode(HttpListenerMode.EmbedIO)) WebServer server = new WebServer(o => o.WithUrlPrefix(url).WithMode(HttpListenerMode.EmbedIO))