Open FritzAlex opened 7 months ago
To troubleshoot the issue you're experiencing with the elsaworkflows/elsa-studio-v3
Docker image running behind a proxy, there are a few things to consider:
Base Path Configuration: Ensure that the Hosting:BasePath
environment variable is set correctly in your Docker run command. This should reflect the base path that the application is accessed from behind the proxy.
Proxy Configuration: Verify that your proxy is correctly configured to rewrite the URLs for the resources that are not loading. Some proxies require specific rules to handle URL rewrites for paths to static resources.
Application Settings: Check if the application's settings, such as appsettings.json
or wwwroot/appsettings.json
, need to be updated to reflect the base path or other proxy-related configurations.
Docker Image Version: Make sure you are using the latest version of the Docker image, as there might have been updates or bug fixes related to running behind a proxy.
Blazor Configuration: Since the files _framework/blazor.webassembly.js
and ElsaStudioWebAssembly.styles.css
are specific to Blazor WebAssembly, you might need to check the Blazor configuration for handling static files and base paths. This can include settings in index.html
or _Host.cshtml
.
Check for Known Issues: Look for any known issues or discussions on the official Elsa GitHub repository or forums that might relate to running the application behind a proxy.
If you've checked all the above and the issue persists, it could be a bug or a missing feature in the Elsa Dashboard's handling of base paths for static resources. In this case, you might want to raise an issue on the official Elsa GitHub repository or seek help from the community in the discussions section.
Since you mentioned that most resources are loading correctly, it suggests that the base path is partially working, but there might be specific static resources that are not respecting the base path setting. This could be due to how the Blazor framework handles static assets or a misconfiguration in the Docker image or the application itself.
If you provide more details about your proxy setup and the exact Docker run command you're using, I could offer more targeted advice.
Hello again,
after further investigation the problem may be here that the @basePath
Variable is not applied on that specific line. May that be the issue to the Problem?
Hey there, yes this might be the problem, although I need to try it to be sure. Although I don't have the bandwidth to try it right now, what I can do is apply the suggested change, since it won't break anyone anyway given that basePath is empty by default. Once the new image is available, you can give it a try and let us know your findings.
Once this build successfully completes, you should be able to pull the newest version of the image (be sure to do a docker pull before doing a run) and see if it helps.
Hey, Thanks for the quick response. The direct error got fixed, but it seems to be a larger rabbithole after that. Now we get this error, seems to be a similar Origin.
hi @sfmskywalker and @FritzAlex, I faced the same issue and I fixed it with these steps:
Add the base path to the Elsa server (Program.cs):
Add the FQDN to the _Host.cshtml belonging to Elsa server, all changed lines are marked in red:
In my case I use Nginx as a gateway, so I added a forwarding route:
and voila, Elsa v3 running behind a proxy:
Of course it is better to pull these paths and URLs from the config, I left them static to depict the solution.
Hi, we are currently trying to get the elsaworkflows/elsa-studio-v3 docker image running behind a proxy and have set the
Hosting:BasePath
environment Variable to the BasePath behind the Proxy. For most of the requested resources it seemed to work, but not for the _framework/blazor.webassembly.js and the ElsaStudioWebAssembly.styles.css files.Is there something on our end that we missed or is this a Bug?