-
Notifications
You must be signed in to change notification settings - Fork 34
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
"add project to machine" button does not work cross-domain #26
Comments
This should be addressed (I just tested by using |
I pulled the new images and tried again, with the same results (I think I had also built them locally when I opened the issue). A more detailed description of what I did:
Then I went to http://localhost:5080 and added the Bayesian-Optimisation JSON file to create the project.
Here's the full FGMachine log:
Let me know if there's more I can do to help debug :) |
Hmmm first check in the machine (via the dashboard) to see if the project got added anyway, and if not, try the button again and see (please attach the FGMachine log again, that's quite useful). I vaguely remember this happening to me as well, but it actually worked fine, or the second time worked. |
Checked http://localhost:5080/machines/<MACHINE_ID>, and the project list is empty. FGMachine log (note it's still the same session as in the previous reply):
Checked again the machine webpage after this, and project list is still empty. |
There might be a conflict with a browser/extension you are using. If you have several extensions activated, please try a version of your default browser without any extensions, and also other browsers (preferably a new one that you install now). Otherwise, perhaps the networking setup with Docker containers is causing the issue, but it all looks fine to me... Unfortunately I won't have time to look into this further until the weekend, so fingers crossed it is a browser issue. |
Was using Chrome, tried with Chrome in private mode, with extensions disabled, and also tried with a clean Firefox. Am using Linux with kernel 4.4.0-96-generic, if it makes any difference. Here are both logs:
FGLab:
No rush on my side, so far working only on one machine, so using the correct domain is an easy workaround :) |
OK I think there's a solution 😄 I replicated your setup with Docker (thanks for the detailed reproduction steps). Accessing FGLab at Rule of thumb, if you're accessing the FGLab dashboard at the address provided in the |
Hi,
Issue #15 implements a button to add a project to a FGMachine, but the way it is implemented only works when both FGLab and FGMachine have the same domain name.
This is the way the HTTP request is currently made:
However, according to the documentation for
contentType
in http://api.jquery.com/jquery.ajax/,This means that currently if
address
is different from the address you're using to access FGLab, an HTTP OPTIONS request will be sent (which as far as I understood FGMachine doesn't know how to deal with), and no PUT request is ever sent.I ran into this problem by running FGLab and FGMachine in docker containers, and accessing FGLab's UI at http://localhost:5080.
I temporarily fixed this by changing the contentType to
text/plain
, but this is not a good solution.The text was updated successfully, but these errors were encountered: