-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added docs for server configuration (#147)
* Added docs for server configuration * Added option to bypass SSL certificate for SignalR in AxoDialogLocator. * Docs update to match the latest change. * Created DeveloperSettings static class and changed BypassSSLCertificate attribute in DialogClient.cs
- Loading branch information
Showing
4 changed files
with
99 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# How to configure Blazor server for Siemens panel | ||
|
||
To configure Blazor Server, you need to follow these two steps: | ||
|
||
## 1. Change the default IP Address | ||
|
||
To modify the IP address of the website, you have two options: | ||
|
||
1. In Program.cs | ||
Inside the Program.cs file, add the following lines to specify the URLs: | ||
|
||
~~~ C# | ||
builder.WebHost.UseUrls("http://10.10.10.198:5262;https://10.10.10.198:7292"); | ||
~~~ | ||
|
||
or | ||
|
||
~~~ C# | ||
builder.WebHost.UseUrls("http://*:5262;https://*:7292"); | ||
~~~ | ||
|
||
2. In launchSettings.json | ||
Open the launchSettings.json file and modify the 'applicationUrl' under the profiles section. For example: | ||
|
||
~~~ JSON | ||
"applicationUrl": "http://10.10.10.198:5262;https://10.10.10.198:7292" | ||
~~~ | ||
|
||
Please note that the IP address corresponds to the IP address of your network adapter. | ||
|
||
## 2. Add rules to the firewall | ||
|
||
Follow these steps to add rules for the desired ports in the Windows Defender Firewall: | ||
|
||
1. Go to Control Panel > Windows Defender Firewall > Advanced Settings | ||
|
||
2. In the Inbound Rules section, add the rules for the ports you wish to use. | ||
|
||
If you are using Eset, you should perform the following steps: | ||
|
||
1. Navigate to Eset > Setup > Network > Click on settings next to Firewall > Configure. | ||
|
||
2. Check the option `Also evaluate rules from Windows Firewall`` or add the rule directly in Eset. | ||
If you using Eset you need to: Eset > Setup > Network > click on settings next to Firewall > Configure | ||
|
||
### Warning | ||
|
||
If you intend to use HTTPS with a self-signed SSL certificate, make sure to adjust the `DeveloperSettings.BypassSSLCertificate` attribute in `Program.cs` to `true`, before start your application. Here's an example of how to do it: | ||
|
||
~~~ C# | ||
DeveloperSettings.BypassSSLCertificate = false; | ||
~~~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace AXOpen.Core.Blazor | ||
{ | ||
public static class DeveloperSettings | ||
{ | ||
/// <summary> | ||
/// Using SSL certificate for SignalR connection (default value is false). | ||
/// </summary> | ||
/// | ||
public static bool BypassSSLCertificate { get; set; } = false; | ||
} | ||
} |