Greetings to all. Unfortunately, they can’t help me with the extension topic, since no one has answered there for months ...

I will try to ask my question here.

I have a Laravel project and I want to integrate it with the Flarum forum. I need users to register in my Laravel application and get to the forum with these accounts. I saw the FoF/Passport package - apparently this is the only solution for my purpose.

I did everything according to the instructions. Installed Passport in Laravel, installed FoF/Passport in Flarum. In the FoF extension, I indicated all the necessary data.

Now, when I click on the login button, I am shown a view with login and cancel buttons. When I click on the authorization button, something starts to load and does it endlessly. Before error 504 - connection timeout.

What could be the reason?

My Flarum runs in a subfolder and I access it as mydomain.com/forum - but I don't think that's the reason.

    LittlePony you can check your browser development tools. Most browser have a "Network" tab that shows every request made by the browser. In that list you can see which URL has a status of 504.

    It might also just be the same URL already displayed in your browser address bar if no iframes or javascript is involved.

    I'm mostly curious about the domain or prefix, to know whether it comes from your Flarum or Laravel.

    The formatting of the error page is also important. Does it look like it was generated by Flarum, Laravel or some webserver/proxy/firewall you use in between?

    Once you know where it comes from you can check the logs of that particular component for error messages.

    I'm curious what could cause a request timeout. It's very unlikely to be an infinite loop, at least on the Flarum side. A more likely cause could be that Flarum is not able to resolve the domain or perform the server-to-server request to Laravel in the background.

      clarkwinkelmann

      Thanks for the help. I completely uninstalled Passport Laravel, Flarum, FoF/Passport and redid the entire installation and setup according to the manual deploying my project to a VPS so that people can help me remotely. It gave some results, but they also do not please me. Now after clicking the "Authorize" button, Flarum gives the error "An error occurred while trying to load this page." I would like to write to you in private messages and provide data so that you can personally look at the console and my settings / database, if you have a few minutes to spare, and tell me what I need to fix. I would be very grateful.

      Currently the URL where the error occurs

      http://myvps.com/forum/auth/passport?code=def5020047bfc2502a623d38dd32e5c6dc1d27d6ceb8cb69f8c1bfad34f6bda06fe4ee66ed2aff0ddeb0776562d7c81ab3b367da6d3fa4615a0cad67990cdb2c123ace7dcfc1a4d45c83ef97d10f1d8783dde06bbddda2886733ceb851e50da5ced7497f9d992cbef4f6c355d4940dfff539cc05aecc73ede8646b57ebff10bf4cc86ee29d2c6c4757c9837e97347b4b1068a107b8ad918df70d0a75fd5891d948fcebdcf1e54ad390595b3b90c293df22831a046ed92a760e59ba2adc01972e61b7c2ce2eef180214c282dd41f13bce74331ffc89e01b857630905341c29927fdd0015903ce5105511ff717e5420c0133999ef1475b6e871fff5dcbe40bf1c48f7979dd0aba1eea5ba03a543da1dca88905f08b393a8fa8494a03cd868222f8dbdc94022907642dfbf8f2cecbd6184875edd278bfe651e11eb23ee0eace3ee925732eb14619cb69068248a361269414a92d486cc83aacfef9c17fba83e669ce63ebe3839c827a01fe6d2e0825b98bfb77f179bd16ad62104d59313c80e7a97fea1cb7c6434ac29178fee9fc76559b&state=f0e6d945834ef96b67fd92dedcdc8384

      Settings FoF/Passport
      FoF/Passport

      Client Laravel/Passport
      Laravel/Passport

      Error Flarum

      LOGS FLARUM:
      flarum.ERROR: InvalidArgumentException: Required option not passed: "access_token" in /var/www/peralta/public/forum/vendor/league/oauth2-client/src/Token/AccessToken.php:96