Skip to content

Commit 2a077f4

Browse files
authored
Merge pull request #657 from snyk/feat/universal-broker-docs-refresh
feat: universal broker docs updates [ACC-2861] [DOCT-1712]
2 parents 24a813e + 15b0047 commit 2a077f4

17 files changed

+130
-85
lines changed

docs/enterprise-setup/snyk-broker/universal-broker/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,21 @@
55
Universal Broker is in Early Access and is available only with Enterprise plans.
66
{% endhint %}
77

8-
The Universal Broker improves the management of Broker deployments and connections, supporting many connections of any type through a single running client, preferably with multiple replicas, that is, entirely distinct clients. Credentials remain entirely local to your network and are never stored on the Snyk platform, which uses credentials references.
8+
The Universal Broker improves the management of Broker deployments and connections by supporting many connections of any type with a single running client (container) or with multiple client replicas. Credentials remain within your network and are never stored by or transmitted to Snyk. The Snyk platform uses credentials references to instruct the Universal Broker how to authenticate with your private resources.
99

10-
Each client or client with replicas is called a Broker deployment. The diagram shows two deployments, Universal Broker A and Universal Broker B.
10+
Each client or set of client replicas is called a Broker deployment. The diagram below shows two deployments, Universal Broker A and Universal Broker B.
1111

12-
A deployment can support multiple connections of any type, as shown in the diagram examples: GitHub, GitLab, Artifactory, Jira, and Container Registry Agent. Connections are configured to communicate with specific private resources: SCMs, JIRA, and others.
12+
A deployment can support multiple connections of any type, as shown in the diagram examples: GitHub, GitLab, Artifactory, Jira, and Container Registry Agent. Connections are configured to communicate with specific private resources: SCMs, Jira, and others.
1313

1414
<figure><img src="../../../.gitbook/assets/image 5 (6).png" alt=""><figcaption><p>Universal Broker deployment example</p></figcaption></figure>
1515

1616
Connections are integrated with Organizations to provide access to your private resources for the appropriate Snyk Organization(s). These Organizations can be in the same or different Snyk Groups.
1717

1818
In the diagram, Group 1 includes Organizations A through D, and Group 2 includes Organizations E and F.
1919

20-
Organizations A, B, C, D, and E are integrated with the Universal Broker A deployment, and thus have access to all of the resources except the container registry agent.&#x20;
20+
Organizations A, B, C, D, and E are integrated with the Universal Broker A deployment, and thus have access to all of the resources except the Container Registry Agent.&#x20;
2121

22-
Organization F is integrated with Universal Broker B, and thus has access to Jira and the container registry agent.
22+
Organization F is integrated with Universal Broker B, and thus has access to Jira and the Container Registry Agent.
2323

2424
{% hint style="info" %}
2525
You can learn more about Universal Broker in the dedicated Snyk Learn course. Explore the advantages, configuration, architecture, and much more with [Snyk Learn: Universal Broker](https://learn.snyk.io/lesson/universal-broker/?ecosystem=general).

docs/enterprise-setup/snyk-broker/universal-broker/add-a-new-connection-to-your-universal-broker.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ A Broker deployment supports numerous connections of any type, including the sam
1010

1111
While the Universal Broker supports multiple connections of the same type, each Organization can be integrated with only one connection for a given type. For example, an Organization cannot be integrated with two GitLab connections.
1212

13-
You can share credentials references across connections by selecting a credentials reference when you create a connection. However, you can share credentials references only across connections of the same type AND running on the same Broker deployment
13+
You can share credentials references across connections by selecting a credentials reference when you create a connection. However, you can share credentials references only across connections of the same type and running on the same Broker deployment.
1414

1515
After the connection is created, run `snyk-broker-config workflows connections integrate` and select the desired deployment and connection. Then enter the Organization ID for the Organization with which you want to integrate. For details, see [Integrate a connection with an Organization](setting-up-and-integrating-your-universal-broker-connections.md#integrate-a-connection-with-an-organization).
1616

docs/enterprise-setup/snyk-broker/universal-broker/basic-steps-to-install-and-configure-universal-broker.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,17 @@ To install the tool, use `npm i -g snyk-broker-config`.
1414
The `snyk-broker-config` CLI tool is your primary guide for setting up and managing Snyk Broker connections. It is designed to walk you step-by-step through the process, asking for the required information for each integration type. This adaptive method guarantees that you receive the latest parameter requirements directly from the tool.
1515
{% endhint %}
1616

17+
The basic process for configuring a new Universal Broker deployment is as follows:
18+
1. Install the `snyk-broker-config` tool by running `npm i -g snyk-broker-config`
19+
2. Create a new Universal Broker connection by following the create workflow `snyk-broker-config workflows connections create`
20+
3. Integrate your new Universal Broker connection by following the integrate workflow `snyk-broker-config workflows connections integrate`
21+
1722
### How to use the CLI for parameter discovery
1823

19-
Even if you are not running the full setup, the Snyk CLI can help you understand the required parameters. Use the interactive setup or the command line help.
24+
Even if you are not running the full setup, the `snyk-broker-config` CLI tool can help you understand the required parameters. Use the interactive setup or the command line help.
2025

2126
* **Interactive setup:** Run `snyk-broker-config workflows connections create` and follow the prompts. The CLI asks for all required and optional parameters based on the integration type you select, such as GitLab, Artifactory, or Bitbucket Server.
22-
* **Command line help:** Use the `--help` flag for any `snyk-broker-config` command to see available options and parameters. For instance, to see parameters specifically relevant for creating a GitLab connection type, use the following command:
27+
* **Command line help:** Use the `--help` flag for any `snyk-broker-config` command to see available options and parameters. For instance, to see parameters specifically relevant for creating a GitLab connection type, use the following command:
2328

2429
```bash
2530
snyk-broker-config workflows connections create --type gitlab --help
@@ -42,7 +47,7 @@ A typical workflow for adding a new Broker connection using the CLI involves the
4247

4348
The CLI will then guide you through the process, prompting for:
4449

45-
* Your Snyk API Token, required for authentication.
50+
* Your Snyk API Token, required for authentication if you did not already export it as an environment variable.
4651
* The Snyk Organization ID where the Broker connection is used.
4752
* The specific type of integration you want to connect, such as `gitlab`, `artifactory`, `bitbucket-server`.
4853
* All required and optional parameters, such as URLs, tokens, usernames, or passwords, are dynamically identified for your chosen integration type. Follow the on-screen instructions carefully.
@@ -100,9 +105,9 @@ Now using Tenant ID <current Tenant ID> and Install ID <current Install ID>.
100105
Do you want to create a new Deployment? (Y/N)
101106
```
102107

103-
Snyk recommends that you set the INSTALL\_ID as an environment variable now, to make the tool easier to use.:\
104-
`- export INSTALL_ID=zzzz (Linux/Mac)`\
105-
`- set INSTALL_ID=zzzz(Windows)`
108+
Snyk recommends that you set the INSTALL_ID as an environment variable to improve usability:\
109+
- `export INSTALL_ID=zzzz` (Linux/Mac)\
110+
- `set INSTALL_ID=zzzz` (Windows)
106111

107112
## Input connection parameters
108113

@@ -180,7 +185,7 @@ Selected Connection ID <number>.
180185
Ready to configure integrations to use this connection.
181186
```
182187

183-
Details of the connection follow: `connection ID`; `connection type (broker_connection)`; `attributes: deployment_id, identifier, name, and secrets-primary and secondary`, each with the `status`, `encrypted`, `expires_at`, and `nonce`; `configuration required: broker-client-url` and `github_token values`; `type: github.`
188+
Details of the connection follow: `connection ID`; `connection type (broker_connection)`; `attributes: deployment_id, identifier, name, and secrets: primary and secondary`, each with the `status`, `encrypted`, `expires_at`, and `nonce`; `configuration required: broker-client-url` and `github_token values`; `type: github.`
184189

185190
```
186191
Connection Detail Workflow completed.
@@ -211,7 +216,6 @@ docker run -d --restart=always \
211216
-p 8000:8000 \
212217
-e DEPLOYMENT_ID=<DEPLOYMENT_ID_JUST_CREATED> \
213218
-e CLIENT_ID=<CLIENT_ID_SAVED_EARLIER> \
214-
215219
-e CLIENT_SECRET=<CLIENT_SECRET_SAVED_EARLIER> \
216220
-e MY_GITHUB_TOKEN=<THE_ACTUAL_GITHUB_TOKEN_VALUE> \
217221
-e PORT=8000 \
@@ -224,7 +228,7 @@ When the Broker client has started, the connection is ready to use, in this case
224228

225229
## Integrate your connection with more Organizations
226230

227-
To integrate your connection with another Organization so it will use the same connection, run the command again and enter the ID of the new Organization to integrate. You can repeat this step as often as needed to integrate with Organizations.
231+
To integrate your connection with another Organization, run the integrate command again and enter the new Organization ID. Repeat as needed to connect with multiple Organizations.
228232

229233
```
230234
> snyk-broker-config workflows connections integrate

docs/enterprise-setup/snyk-broker/universal-broker/broker-client-url.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ The same webhook mechanism is used to facilitate communication when Snyk creates
1010

1111
When you set up a connection, the webhook target endpoint is defined by the value of the `broker_client_url` value. The webhook can point directly to Snyk or to the Broker client container, which will relay the webhook to Snyk.&#x20;
1212

13-
Normally, and by default for SCM integrations, the regional Snyk API endpoint is used. For the list of URLs, see [Broker client URLs](../../../working-with-snyk/regional-hosting-and-data-residency.md#broker-client-urls). Sometimes, however, your environment may prohibit SCM webhooks from leaving the private cloud or data center. In that case, the webhook and thus the SCM must point to the Snyk Broker container running in your environment. In these cases, the`broker_client_url` has to reflect the hostname and port of the Broker client.&#x20;
13+
By default, SCM integrations use the regional Snyk API endpoint. For the list of URLs, see [Broker client URLs](../../../working-with-snyk/regional-hosting-and-data-residency.md#broker-client-urls). Sometimes, environments restrict SCM webhooks from leaving the private cloud or data center. In is scenario, the webhook and SCM must point to the Snyk Broker container in your environment, with `broker_client_url` reflecting the hostname and port of the Broker client.
1414

1515
Non-SCM integrations, notably the container registries integrations, require the Broker client URL to be the Broker client address. Snyk recommends using the DNS hostname (`http://my.broker.client`), but you can also use IP addresses (`http://192.168.0.1`). Append the port, for example, `http://my.broker.client:8000`.
1616

17-
Note that the `https` webhook calls requires additional setup in the Broker client to bring a TLS certificate and mount it into the container. For details, see [HTTPS for Broker client with Docker](../https-for-broker-client-with-docker.md).
17+
Note that the `https` webhook calls require additional setup in the Broker client to bring a TLS certificate and mount it into the container. For details, see [HTTPS for Broker client with Docker](../https-for-broker-client-with-docker.md).

docs/enterprise-setup/snyk-broker/universal-broker/deployment-tips-and-reference-architectures.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,24 @@ You can learn more about deployment and architecture, and more, with the [Univer
66

77
The Universal Broker allows you to run multiple connections of any type using a single container. Snyk recommends running in High Availability Mode (on by default), to run multiple replicas.
88

9-
On Kubernetes systems, the Helm chart creates a stateful set with numerous members, automatically creating multiple replicas.
9+
On Kubernetes, the Helm chart creates a stateful set with numerous members, automatically creating multiple replicas.
1010

11-
In other orchestrators, you must create multiple replicas explicitly in your deployment configuration.
11+
In other orchestrators such as Docker Compose, you must create multiple replicas explicitly in your deployment configuration.
1212

1313
Usage of resources varies based on a number of factors, making it difficult to model the actual use of resources (CPU and memory) for the container. Each deployment is limited to a maximum of 25 connections to avoid exhaustion of resources.
1414

1515
If you find you need more resource segregation or allocation that does not fit well into a single container setup, you can create a new deployment with its set of connections to split the load across numerous Broker clients and containers.
1616

17-
Note that moving connections from deployment A to deployment B is not supported.
17+
Note that moving connections from one deployment to another is not supported.
1818

1919
Contact your Snyk account team or [Snyk support](https://support.snyk.io/s/) if you need more assistance designing a Universal Broker architecture for your needs.
2020

21+
## High Availability Mode
22+
23+
High Availability Mode for a Universal Broker deployment is enabled by default and can be disabled by setting the `BROKER_HA_MODE_ENABLED=false` environment variable inside the container. When HA mode is enabled the Universal Broker deployment will open a second backup websocket with the Snyk platform to provide redundancy in the event of a network failure.
24+
25+
Each Universal Broker deployment is limited to 4 total web sockets. They can be deployed in any configuration such as two Universal Broker Clients each with HA mode enabled, or four Universal Broker Clients with HA mode disabled. When deploying the Universal Broker using the [Snyk Universal Broker Helm chart](https://github.com/snyk/snyk-universal-broker-helm/blob/rc/snyk-universal-broker/values.yaml#L66) the default configuration is 2 replicas with HA mode enabled.
26+
27+
Note that exceeding 4 web sockets per Universal Broker deployment will result in unpredictable and unstable behaviour for all broker clients in the deployment.
28+
2129
\

docs/enterprise-setup/snyk-broker/universal-broker/disconnect-and-clean-up.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# Disconnect and clean up
22

3-
The `snyk-broker-config workflows <RESOURCE> delete` commands allow you to remove resources.&#x20;
3+
The `snyk-broker-config workflows <RESOURCE> delete` command allows you to remove resources.&#x20;
44

55
Protections are in place to prevent invalid connection states, so you cannot delete connections that are integrated, and therefore relied upon, by Organizations. You must disconnect the integration before deleting the connection.
66

7-
`snyk-broker-config workflows connections delete` walks you through the disconnection steps.
7+
The `snyk-broker-config workflows connections disconnect` command walks you through the disconnection steps.
88

99
For all resources, you must delete the child items before you can delete a parent, as illustrated in the diagram that follows. A deployment contains connections and credentials references. Connections use credentials references. Each connection may have an integration with one or more Organizations.
1010

11-
`snyk-broker-config` commands walk you through this flow and indicate what needs to be done to achieve successful deletion. These commands implement and enforce the following rules:
11+
The `snyk-broker-config introduction` command walks you through this flow and indicates what needs to be done to achieve successful deletion. These commands implement and enforce the following rules:
1212

1313
* Before you delete a connection, you must disconnect all integrations.
1414
* Before you delete a credentials reference, you must delete the connection(s) using it.
@@ -33,7 +33,7 @@ In response to the prompt, type Y and press Enter if you want to disconnect all
3333
```
3434
Universal Broker - Delete Connection Workflow
3535
✓ Valid Snyk Token.
36-
✓ Tenant Adnmim role confirms.
36+
✓ Tenant Admin role confirms.
3737
Now using Tenant ID of <returned number>.
3838
Now using Deployment <returned number>.
3939
Which Connection do you want to use? <number entered>
@@ -43,7 +43,7 @@ Do you want to disconnect them all? (Y/N)
4343

4444
## Disconnect integrations
4545

46-
To delete multiple integrations, run s`nyk-broker-config workflows connections disconnect`.
46+
To delete multiple integrations, run `snyk-broker-config workflows connections disconnect`.
4747

4848
Enter the connection from which to disconnect.
4949

@@ -58,9 +58,8 @@ Now using Deployment <number returned>.
5858
Which Connection do you want to use <number entered>
5959
Selected Connection ID <number entered>. Ready to disconnect integrations using
6060
this connection.
61-
Select (Press <backspace> to remove option) {Type: github] in <Organization ID returned>
62-
[✓ ] Type github in <Organization ID returned> integr <number returned>)
63-
[ ] Type github in <Organization ID returned>? integr <number returned>)
61+
Select (Press <backspace> to remove option) [Type: github] in <Organization ID returned>
62+
[✓ ] Type github in <Organization ID returned> (integration <Integration ID returned>)
6463
```
6564

6665
## Delete credentials references

docs/enterprise-setup/snyk-broker/universal-broker/list-and-review-the-universal-broker-configuration-resources.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,21 @@ The `snyk-broker-config` CLI tool provides resources to guide you in configuring
77
* Deployments
88
* Integrations
99

10-
To list the resources, run `snyk-broker-config-workflows`.
10+
To list the workflows available, run `snyk-broker-config workflows`.
1111

1212
```
13-
> snyk-broker-config-workflows
13+
> snyk-broker-config workflows
1414
Interactive workflows for Deployments, Credentials, Connections and
1515
Integrations management
1616
1717
USAGE
18-
$ snyk-broker.config workflows COMMAND
18+
$ snyk-broker-config workflows COMMAND
1919
2020
TOPICS
2121
workflows connections Universal Broker - Create Connection Workflow
22-
workflows credentials. Universal Broker - Create Credentials Workflow
22+
workflows credentials Universal Broker - Create Credentials Workflow
2323
workflows deployments Universal Broker - Create Deployment Workflow
24-
workflows integration. Universal Broker - Get Connection Integration Workflow
24+
workflows integration Universal Broker - Get Connection Integration Workflow
2525
```
2626

2727
Run `snyk-broker-config workflows <RESOURCE>` to list the available resources to get, create, delete, disconnect, integrate, and migrate.

0 commit comments

Comments
 (0)