Skip to content

Commit bff8d72

Browse files
feat: update adminconsole version (#1431)
* updated adminconsole version * fix playwright tests * fix playwright tests * fix playwright tests * fix playwright tests --------- Co-authored-by: emosbaugh <[email protected]> Co-authored-by: Ethan Mosbaugh <[email protected]>
1 parent b963225 commit bff8d72

File tree

8 files changed

+71
-14
lines changed

8 files changed

+71
-14
lines changed

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,7 @@ create-node%:
306306
-v $(shell pwd):/replicatedhq/embedded-cluster \
307307
-v $(shell dirname $(shell pwd))/kots:/replicatedhq/kots \
308308
$(if $(filter node0,node$*),-p $(NODE_PORT):$(NODE_PORT)) \
309+
$(if $(filter node0,node$*),-p 30003:30003) \
309310
replicated/ec-distro:$(DISTRO)
310311

311312
@$(MAKE) ssh-node$*

e2e/playwright/README.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
## Running Tests Against the Development Environment
2+
3+
1. Install deps on your Mac
4+
5+
```bash
6+
npm ci
7+
npx playwright install --with-deps
8+
code --install-extension ms-playwright.playwright
9+
```
10+
11+
1. Build the release and run the development environment
12+
13+
```bash
14+
make initial-release
15+
make create-node0
16+
output/bin/embedded-cluster install --license local-dev/license.yaml
17+
```
18+
19+
1. Create a nodeport service directly to kotsadm
20+
21+
```bash
22+
cat <<EOF | k0s kubectl apply -f -
23+
apiVersion: v1
24+
kind: Service
25+
metadata:
26+
name: kotsadm-nodeport
27+
namespace: kotsadm
28+
labels:
29+
replicated.com/disaster-recovery: infra
30+
replicated.com/disaster-recovery-chart: admin-console
31+
spec:
32+
type: NodePort
33+
ports:
34+
- port: 30003
35+
targetPort: 3000
36+
nodePort: 30003
37+
selector:
38+
app: kotsadm
39+
EOF
40+
```
41+
42+
1. Configure the base URL (default is `http://localhost:30000`) on your Mac
43+
44+
```bash
45+
export BASE_URL=http://localhost:30003
46+
```
47+
48+
1. Run the test on your Mac
49+
50+
```bash
51+
npx playwright test --ui deploy-app
52+
```
53+
54+
Don't forget to press the play button in the browser to run the test.

e2e/playwright/tests/deploy-upgrade/test.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ test('deploy upgrade', async ({ page }) => {
1515
await iframe.locator('input[type="password"]').fill('updated password');
1616
await iframe.getByRole('button', { name: 'Next', exact: true }).click();
1717
await expect(iframe.getByText('Preflight checks', { exact: true })).toBeVisible({ timeout: 10 * 1000 });
18-
await expect(iframe.getByRole('button', { name: 'Re-run' })).toBeVisible({ timeout: 10 * 1000 });
18+
await expect(iframe.getByRole('button', { name: 'Rerun' })).toBeVisible({ timeout: 10 * 1000 });
1919
await expect(iframe.locator('#app')).toContainText('Embedded Cluster Installation CRD exists');
2020
await expect(iframe.locator('#app')).toContainText('Embedded Cluster Config CRD exists');
2121
await expect(iframe.getByRole('button', { name: 'Back: Config' })).toBeVisible();

e2e/playwright/tests/get-restore-join-controller-command/test.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { login } from '../shared';
33

44
test('get restore join controller command', async ({ page }) => {
55
await login(page);
6+
await page.getByRole('button', { name: 'Add node', exact: true }).click();
67
await expect(page.locator('#controller-testNodeType')).toBeChecked();
78
await expect(page.locator('.CodeSnippet-copy')).toBeVisible();
89
const joinCommand = await page.locator('.react-prism.language-bash').first().textContent();

e2e/playwright/tests/shared/deploy-app.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ export const deployApp = async (page, expect) => {
1010
await page.locator('input[type="password"]').click();
1111
await page.locator('input[type="password"]').fill('password');
1212
await page.getByRole('button', { name: 'Continue' }).click();
13-
await expect(page.getByText('Preflight checks', { exact: true })).toBeVisible({ timeout: 10 * 1000 });
14-
await expect(page.getByRole('button', { name: 'Re-run' })).toBeVisible({ timeout: 10 * 1000 });
13+
await expect(page.getByText('Validate the environment')).toBeVisible({ timeout: 10 * 1000 });
14+
await expect(page.getByRole('button', { name: 'Rerun' })).toBeVisible({ timeout: 10 * 1000 });
1515
await expect(page.locator('#app')).toContainText('Embedded Cluster Installation CRD exists');
1616
await expect(page.locator('#app')).toContainText('Embedded Cluster Config CRD exists');
1717
await page.getByRole('button', { name: 'Deploy' }).click();

go.mod

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,7 @@ require (
206206
github.com/prometheus/common v0.60.0 // indirect
207207
github.com/prometheus/procfs v0.15.1 // indirect
208208
github.com/redis/go-redis/v9 v9.5.2 // indirect
209+
github.com/rogpeppe/go-internal v1.13.1 // indirect
209210
github.com/rubenv/sql-migrate v1.7.0 // indirect
210211
github.com/sagikazarmark/locafero v0.6.0 // indirect
211212
github.com/sagikazarmark/slog-shim v0.1.0 // indirect

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -907,8 +907,8 @@ github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
907907
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
908908
github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ=
909909
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
910-
github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8=
911-
github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4=
910+
github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII=
911+
github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o=
912912
github.com/rs/cors v1.11.1 h1:eU3gRzXLRK57F5rKMGMZURNdIG4EoAmX8k94r9wXWHA=
913913
github.com/rs/cors v1.11.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU=
914914
github.com/rubenv/sql-migrate v1.7.0 h1:HtQq1xyTN2ISmQDggnh0c9U3JlP8apWh8YO2jzlXpTI=

pkg/addons/adminconsole/static/metadata.yaml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,26 +5,26 @@
55
# $ make buildtools
66
# $ output/bin/buildtools update addon <addon name>
77
#
8-
version: 1.119.1
8+
version: 1.120.0
99
location: oci://proxy.replicated.com/anonymous/registry.replicated.com/library/admin-console
1010
images:
1111
kotsadm:
1212
repo: proxy.replicated.com/anonymous/kotsadm/kotsadm
1313
tag:
14-
amd64: v1.119.1-amd64@sha256:b8411f22fa77554474703af55fbbe2baff7da6ee3c01423fc285b2f675391abe
15-
arm64: v1.119.1-arm64@sha256:e5aa6b35649af9d6160055873a27bb76a4ae551e69685968a6cb73c9dc57e74f
14+
amd64: v1.120.0-amd64@sha256:4538a281a43f95f2b2dad534cfbf0b8493faa29c2959684ee7429eb04c7e79bb
15+
arm64: v1.120.0-arm64@sha256:150ce42b94ad2720aecb07b2c890962ffe5875531111b8f18d083a280369f6ce
1616
kotsadm-migrations:
1717
repo: proxy.replicated.com/anonymous/kotsadm/kotsadm-migrations
1818
tag:
19-
amd64: v1.119.1-amd64@sha256:30a001ae10048b1e07d73dcdd6c575603826c6363f8d3992c3bccfd68ead5df3
20-
arm64: v1.119.1-arm64@sha256:000ec5f6e479f7c87f6c07ed6a6def6f1be79b370950df2ba01cd7965ca4496b
19+
amd64: v1.120.0-amd64@sha256:43abd09a1d5157c53352ea29d94d10dcae5c340923afa5d1bf8765becab347ce
20+
arm64: v1.120.0-arm64@sha256:2e5cb8e30b383c62ea910f89294220a571dd6956d03507f04278cc2f3e5f79ec
2121
kurl-proxy:
2222
repo: proxy.replicated.com/anonymous/kotsadm/kurl-proxy
2323
tag:
24-
amd64: v1.119.1-amd64@sha256:44e8939d8101b5aeeb44087d7e8cbb23054e2004c86525342f32aa4d9e86371f
25-
arm64: v1.119.1-arm64@sha256:53f0dd72f2ed4d95445d91af435f89a957b9abeacd30fe951069bce35b11934c
24+
amd64: v1.120.0-amd64@sha256:e519cc3ccc7a392a762999c0839f031f1444ff9c9bef4908af742399852d98f5
25+
arm64: v1.120.0-arm64@sha256:d22c10e07f7cb16c7e535bf0c69e196b92fe2be63befe3ba0d48993a4a5ef0e4
2626
rqlite:
2727
repo: proxy.replicated.com/anonymous/kotsadm/rqlite
2828
tag:
29-
amd64: 8.31.3-r0-amd64@sha256:575844e0b531567660ea9782c6aaab827af2d8bcff4ca5769c4ea5c6df3e5f8a
30-
arm64: 8.31.3-r0-arm64@sha256:84bcef9357d1f83df2a742e14a5b6be12d4adbf7522682f565ed024374bda17f
29+
amd64: 8.32.4-r0-amd64@sha256:5756786db1e4ae8490b8f37d9fb52c102c962896f8d3276d3e8e3420aff7a2eb
30+
arm64: 8.32.4-r0-arm64@sha256:5b63a08af531e328439fc79ddb4f0b83cddabdf84dfa2ab683fbf7381fd9a127

0 commit comments

Comments
 (0)