Skip to content

Commit 128abda

Browse files
committed
Merge branch 'main' of https://github.com/coder/coder into bq/add-e2e-for-create-and-remove-groups
2 parents 3b260c8 + bc9ea61 commit 128abda

File tree

5 files changed

+130
-20
lines changed

5 files changed

+130
-20
lines changed

.github/workflows/ci.yaml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -478,13 +478,6 @@ jobs:
478478
DEBUG: pw:api
479479
working-directory: site
480480

481-
# Run all of the tests with an enterprise license
482-
- run: pnpm playwright:test --forbid-only --workers 1
483-
env:
484-
DEBUG: pw:api
485-
CODER_E2E_ENTERPRISE_LICENSE: ${{ secrets.CODER_E2E_ENTERPRISE_LICENSE }}
486-
working-directory: site
487-
488481
- name: Upload Playwright Failed Tests
489482
if: always() && github.actor != 'dependabot[bot]' && runner.os == 'Linux' && !github.event.pull_request.head.repo.fork
490483
uses: actions/upload-artifact@v4

docs/about/architecture.md

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,3 +162,109 @@ offer the fastest developer experience.
162162
- Session persistence (sticky sessions) can be disabled as _coderd_ instances
163163
are stateless.
164164
- WebSocket and long-lived connections must be supported.
165+
166+
### Multi-cloud architecture
167+
168+
By distributing Coder workspaces across different cloud providers, organizations
169+
can mitigate the risk of downtime caused by provider-specific outages or
170+
disruptions. Additionally, multi-cloud deployment enables organizations to
171+
leverage the unique features and capabilities offered by each cloud provider,
172+
such as region availability and pricing models.
173+
174+
![Architecture Diagram](../images/architecture-multi-cloud.png)
175+
176+
#### Components
177+
178+
The deployment model comprises:
179+
180+
- `coderd` instances deployed within a single region of the same cloud provider,
181+
with replicas strategically distributed across availability zones.
182+
- Workspace provisioners deployed in each cloud, communicating with `coderd`
183+
instances.
184+
- Workspace proxies running in the same locations as provisioners to optimize
185+
user connections to workspaces for maximum speed.
186+
187+
Due to the relatively large overhead of cross-regional communication, it is not
188+
advised to set up multi-cloud control planes. It is recommended to keep coderd
189+
replicas and the database within the same cloud-provider and region.
190+
191+
Note: The _multi-cloud architecture_ follows the deployment principles outlined
192+
in the _multi-region architecture_. However, it adapts component selection based
193+
on the specific cloud provider. Developers can initiate workspaces based on the
194+
nearest region and technical specifications provided by the cloud providers.
195+
196+
##### Workload resources
197+
198+
**Workspace provisioner**
199+
200+
- _Security recommendation_: Create a long, random pre-shared key (PSK) and add
201+
it to the regional secret store, so that local _provisionerd_ can access it.
202+
Remember to distribute it using safe, encrypted communication channel. The PSK
203+
must also be added to the _coderd_ configuration.
204+
205+
**Workspace proxy**
206+
207+
- _Security recommendation_: Use `coder` CLI to create
208+
[authentication tokens for every workspace proxy](../admin/workspace-proxies.md#requirements),
209+
and keep them in regional secret stores. Remember to distribute them using
210+
safe, encrypted communication channel.
211+
212+
**Managed database**
213+
214+
- For AWS: _Amazon RDS for PostgreSQL_
215+
- For Azure: _Azure Database for PostgreSQL - Flexible Server_
216+
- For GCP: _Cloud SQL for PostgreSQL_
217+
218+
##### Workload supporting resources
219+
220+
**Kubernetes platform (optional)**
221+
222+
- For AWS: _Amazon Elastic Kubernetes Service_
223+
- For Azure: _Azure Kubernetes Service_
224+
- For GCP: _Google Kubernetes Engine_
225+
226+
See how to deploy
227+
[Coder on Azure Kubernetes Service](https://github.com/ericpaulsen/coder-aks).
228+
229+
Learn more about [security requirements](../install/kubernetes.md) for deploying
230+
Coder on Kubernetes.
231+
232+
**Load balancer**
233+
234+
- For AWS:
235+
- _AWS Network Load Balancer_
236+
- Level 4 load balancing
237+
- For Kubernetes deployment: annotate service with
238+
`service.beta.kubernetes.io/aws-load-balancer-type: "nlb"`, preserve the
239+
client source IP with `externalTrafficPolicy: Local`
240+
- _AWS Classic Load Balancer_
241+
- Level 7 load balancing
242+
- For Kubernetes deployment: set `sessionAffinity` to `None`
243+
- For Azure:
244+
- _Azure Load Balancer_
245+
- Level 7 load balancing
246+
- Azure Application Gateway
247+
- Deploy Azure Application Gateway when more advanced traffic routing
248+
policies are needed for Kubernetes applications.
249+
- Take advantage of features such as WebSocket support and TLS termination
250+
provided by Azure Application Gateway, enhancing the capabilities of
251+
Kubernetes deployments on Azure.
252+
- For GCP:
253+
- _Cloud Load Balancing_ with SSL load balancer:
254+
- Layer 4 load balancing, SSL enabled
255+
- _Cloud Load Balancing_ with HTTPS load balancer:
256+
- Layer 7 load balancing
257+
- For Kubernetes deployment: annotate service (with ingress enabled) with
258+
`kubernetes.io/ingress.class: "gce"`, leverage the `NodePort` service
259+
type.
260+
- Note: HTTP load balancer rejects DERP upgrade, Coder will fallback to
261+
WebSockets
262+
263+
**Single sign-on**
264+
265+
- For AWS:
266+
[AWS IAM Identity Center](https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html)
267+
- For Azure:
268+
[Microsoft Entra ID Sign-On](https://learn.microsoft.com/en-us/entra/identity/app-proxy/)
269+
- For GCP:
270+
[Google Cloud Identity Platform](https://cloud.google.com/architecture/identity/single-sign-on)
189 KB
Loading

site/e2e/playwright.config.ts

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
import { defineConfig } from "@playwright/test";
22
import * as path from "path";
3-
import { coderMain, coderPort, coderdPProfPort, gitAuth } from "./constants";
3+
import {
4+
coderMain,
5+
coderPort,
6+
coderdPProfPort,
7+
enterpriseLicense,
8+
gitAuth,
9+
} from "./constants";
410

511
export const wsEndpoint = process.env.CODER_E2E_WS_ENDPOINT;
612

@@ -43,17 +49,22 @@ export default defineConfig({
4349
},
4450
webServer: {
4551
url: `http://localhost:${coderPort}/api/v2/deployment/config`,
46-
command:
47-
`go run -tags embed ${coderMain} server ` +
48-
`--global-config $(mktemp -d -t e2e-XXXXXXXXXX) ` +
49-
`--access-url=http://localhost:${coderPort} ` +
50-
`--http-address=localhost:${coderPort} ` +
51-
`--in-memory --telemetry=false ` +
52-
`--dangerous-disable-rate-limits ` +
53-
`--provisioner-daemons 10 ` +
54-
`--provisioner-daemons-echo ` +
55-
`--web-terminal-renderer=dom ` +
56-
`--pprof-enable`,
52+
command: [
53+
`go run -tags embed ${coderMain} server`,
54+
"--global-config $(mktemp -d -t e2e-XXXXXXXXXX)",
55+
`--access-url=http://localhost:${coderPort}`,
56+
`--http-address=localhost:${coderPort}`,
57+
// Adding an enterprise license causes issues with pgcoord when running with `--in-memory`.
58+
!enterpriseLicense && "--in-memory",
59+
"--telemetry=false",
60+
"--dangerous-disable-rate-limits",
61+
"--provisioner-daemons 10",
62+
"--provisioner-daemons-echo",
63+
"--web-terminal-renderer=dom",
64+
"--pprof-enable",
65+
]
66+
.filter(Boolean)
67+
.join(" "),
5768
env: {
5869
...process.env,
5970

site/e2e/tests/updateTemplate.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ test("add and remove a group", async ({ page }) => {
4242

4343
// Now remove the group
4444
await row.getByLabel("More options").click();
45-
await page.getByText("Delete").click();
45+
await page.getByText("Remove").click();
4646
await expect(page.getByText("Group removed successfully!")).toBeVisible();
4747
await expect(row).not.toBeVisible();
4848
});

0 commit comments

Comments
 (0)