From 83c7134a14febe4c6576ef8775a94c807d0cd500 Mon Sep 17 00:00:00 2001 From: Brian Vanderbusch Date: Wed, 6 Nov 2024 09:09:16 -0600 Subject: [PATCH] configuraiton of remote download proxy --- docs/source/quickstart.mdx | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/docs/source/quickstart.mdx b/docs/source/quickstart.mdx index 9e6649d1a77..d945442a256 100644 --- a/docs/source/quickstart.mdx +++ b/docs/source/quickstart.mdx @@ -23,6 +23,8 @@ Hello! This tutorial walks you through installing the router (GraphOS Router or If you have a bash-compatible terminal, you can download the latest version of the Apollo Router Core directly to your current directory with the following command: +\*Note: If you are behind a network proxy, set `APOLLO_ROUTER_DOWNLOAD_REMOTE` first. see: ([configuring a proxy for the binary download](#configuring-a-proxy-for-the-binary-download))\* + ```bash curl -sSL https://router.apollo.dev/download/nix/latest | sh ``` @@ -265,6 +267,29 @@ That's it! Running the router with the `--dev` flag enables a development mode t Visit `http://127.0.0.1:4000` to open Apollo Sandbox, inspect your entire supergraph, and run your first queries! +## Configuring a Proxy for the Binary Download + +The installer from step 1 downloads from github, and can be configured to support a proxy artifact repository by +setting the `APOLLO_ROUTER_DOWNLOAD_REMOTE` environment variable to point to your artifact proxy repository +for this github repositories releases/download path on your proxy. + +For example, if your artifact proxy mirror has a hostname of `my-artifact-mirror`, and the proxy for github +is available at `my-artifact-mirror.com/artifacts/github-com`, you would want to set the value of +`APOLLO_ROUTER_DOWNLOAD_REMOTE` like so: + +```bash +export APOLLO_ROUTER_DOWNLOAD_REMOTE="https://my-artifact-mirror.com/artifacts/github-com/apollograpqhl/router/releases/download" +# proceed to run installation script +curl -sSL https://router.apollo.dev/download/nix/latest | sh +``` + +If your remote proxy requires authentication, you can configure that as part of the remote connection string. +Be aware that this will cause the password to appear in plaintext in the command output: + +```bash +export APOLLO_ROUTER_DOWNLOAD_REMOTE="https://:@myartifact-mirror...." +``` + ## Next steps Now that you know how to run the router with a supergraph schema, you can: