1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-13 10:22:42 +01:00
phorge-phorge/src/applications/conduit/controller
epriestley d94d1da610 Proxy Diffusion Conduit API calls
Summary:
Fixes T7020. When an external user makes a Conduit request to Diffusion but the repository isn't hosted locally, we need to proxy it.

This also adds a guard layer to prevent requests from getting infinitely proxied inside the cluster.

In "trivial" configurations (where the repository is a service repository, but the service is on the local device) I'm making us always proxy anyway. This basically makes it reasonable to test this stuff (otherwise you'd have to set up two different installs) and this configuration doesn't make much sense in real life (if you're using multiple machines, making one a dedicating daemons+repo box is almost certainly the most reasonable configuration, even for a cluster size of 2).

Test Plan:
  - With a service-hosted repository, made Diffusion conduit calls and browsed the UI. Verified requests got proxied once, then resovled.
  - With a non-service repository, made Diffusion conduit calls and browsed UI. Verified requests were handled in-process immediately.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T7020

Differential Revision: https://secure.phabricator.com/D11475
2015-01-23 13:30:52 -08:00
..
PhabricatorConduitAPIController.php Proxy Diffusion Conduit API calls 2015-01-23 13:30:52 -08:00
PhabricatorConduitConsoleController.php Conduit - document that ERR-CONDUIT-CORE is coming atchya 2015-01-06 14:41:28 -08:00
PhabricatorConduitController.php Increase visibility of PhabricatorController::buildApplicationMenu methods 2015-01-16 07:41:26 +11:00
PhabricatorConduitListController.php Decouple some aspects of request routing and construction 2014-10-17 05:01:40 -07:00
PhabricatorConduitLogController.php Remove @group annotations 2014-07-10 08:12:48 +10:00
PhabricatorConduitTokenController.php Remove @group annotations 2014-07-10 08:12:48 +10:00
PhabricatorConduitTokenEditController.php Generate and use "cluster" Conduit API tokens 2014-12-15 11:15:14 -08:00
PhabricatorConduitTokenHandshakeController.php Add conduit.getcapabilities and a modern CLI handshake workflow 2014-12-15 11:14:53 -08:00
PhabricatorConduitTokenTerminateController.php Add Conduit Tokens to make authentication in Conduit somewhat more sane 2014-12-15 11:14:23 -08:00