WAGO CC100 hosting an Blazor Web App

Hello WAGO Community,

I’m hoping you guys can help me with a problem I’m having deploying a Blazor Server app on my WAGO Compact Controller 100 (CC100). I am trying to run the app within a Docker container along with Nginx as a reverse proxy, but have run into some challenges.

Background:
I have developed a Blazor server app that I want to host on the CC100. To run the app in an isolated environment, I have installed Docker on the CC100. My goal is to use Nginx to forward requests to the Blazor app running inside the same container on port 5000 while Nginx listens on port 8080.

Problem:
Port assignment conflict: when starting the container, I noticed that both Nginx and the Blazor app were using the same port (8080). This resulted in the default Nginx page being displayed and I could not access the Blazor app.

Solution steps:

I adjusted the Blazor app configuration so that it listens on port 5000 while Nginx stays on port 8080. This should allow Nginx to accept requests on port 8080 and forward them to the Blazor app on port 5000.
I have configured the nginx.conf file so that Nginx acts as a reverse proxy, but I am still having trouble reaching the app through the web browser

Current configuration:
Blazor app: Now runs on port 5000.
Nginx: Listens on port 8080 and forwards requests to the Blazor app on port 5000.
Docker setup: Both services (Nginx and the Blazor app) run in the same Docker container.
Logs and error messages:
Nginx starts without errors, but the forwarding to the Blazor app does not seem to work correctly.
The Blazor app seems to be running properly on port 5000, but I can’t reach it via Nginx.
Questions:
Has anyone had similar experiences and can give me troubleshooting tips?
Are there any specific settings or peculiarities when using Docker and Nginx on the CC100 that I should be aware of?
Could it be due to resource limitations on the CC100, or are there any known issues with this type of setup?
I appreciate any help or suggestions!

Many thanks in advance!

Best regards,
Jan

Not familiar with Blazor, but you can :

  • check the logs
  • check which ports are exposed

netstat -tulpn

  • try running on another port than 8080. It might be used by the webvisualisation. Not sure if it might lead to a conflict if you don’t used it but there are some redirect rules in lighttpd config.

As a general rule I would isolate both services in 2 different containers. You could create a dedicated docker network in order to link them.

Have you tried to use it on another device ?

Thank you very much for your quick reply!

I haven’t tested it on another device yet, as I currently only have the WAGO CC100 available. However, I have already tried using other ports to avoid possible conflicts, but unfortunately that didn’t solve the problem.

Your suggestion to isolate the services into two separate containers sounds promising. I will try that out and see if it brings the desired success.

Thanks again for your support!

Best regards,
Jan