-
Notifications
You must be signed in to change notification settings - Fork 0
Error in setting cookie (previously: "Cross-site POST form submissions are forbidden error") #142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
After better understanding of #141, I could test again with I now build the app and the run it via
where When I try to log in, I correctly see a call to fractal-server endpoint ( The svelte logs read
My best guess is now that I need to better set the |
Cross-site POST form submissions are forbidden
errorCross-site POST form submissions are forbidden
error~~ error while setting cookie
Cross-site POST form submissions are forbidden
error~~ error while setting cookie
To test: set |
Possibly relevant ref: https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxypassreversecookiedomain |
For the record, this is definitely needed - and it leads to the cookie being set in the browser. The next issue now is that the call to fastapi
|
It could also be relevant this https://kit.svelte.dev/docs/adapter-node#environment-variables
|
Here is a config set that currently works.
fractal-server configWhen serving with uvicorn, host should be set to XXXX (e.g. via Note that we did not set any value for fractal-web configFirst we set
After
(see https://kit.svelte.dev/docs/adapter-node#environment-variables) Apache proxy configA minimal working configuration reads like
|
There is now a minimal example of configuration settings in https://github.com/fractal-analytics-platform/fractal-web/tree/main/examples/config_1, to be tested again once we switch to https or if we use a different apache configuration. |
I am using the following setup:
On the remote machine:
npm run dev
(I cannot actually build it, for the moment, due toAUTH_COOKIE_NAME
error innpm run build
#141), on port 5174./etc/apache2/sites-available/fractal-web.conf
:As a first attempt, I added
ORIGIN=http://localhost:80
orORIGIN=http://localhost:5174
to my.env
file, but this changed nothing. The same is true forPROTOCOL_HEADER=x-forwarded-proto HOST_HEADER=x-forwarded-host
.This is likely an error in the svelte configuration, see e.g.:
The text was updated successfully, but these errors were encountered: