Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 98 additions & 0 deletions .github/workflows/twa_frontend_tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
name: TWA Frontend Tests
on:
pull_request:
paths:
- components/crud-web-apps/tensorboards/frontend/**
- releasing/version/VERSION
branches:
- main
- v*-branch
- notebooks-v1

jobs:
frontend-format-linting-check:
name: Code format and lint
runs-on: ubuntu-22.04
defaults:
run:
working-directory: components/crud-web-apps/tensorboards/frontend

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 16

- name: Format tensorboards web app
run: |
npm ci
npm run format:check

- name: Lint tensorboards web app
run: |
npm ci
npm run lint-check

frontend-unit-tests:
runs-on: ubuntu-22.04
name: Unit tests
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup node version to 16
uses: actions/setup-node@v4
with:
node-version: 16

- name: Install common library dependencies
run: |
cd components/crud-web-apps/common/frontend/kubeflow-common-lib
npm ci
npm run build
npm link ./dist/kubeflow

- name: Install TWA dependencies
run: |
cd components/crud-web-apps/tensorboards/frontend
npm ci
npm link kubeflow

- name: Run unit tests
run: |
cd components/crud-web-apps/tensorboards/frontend
npm run test:prod

frontend-ui-tests:
name: UI tests with Cypress
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 16

- name: Install common library dependencies
run: |
cd components/crud-web-apps/common/frontend/kubeflow-common-lib
npm ci
npm run build
npm link ./dist/kubeflow

- name: Install TWA dependencies
run: |
cd components/crud-web-apps/tensorboards/frontend
npm ci
npm link kubeflow

- name: Serve UI & run Cypress tests in Chrome and Firefox
run: |
cd components/crud-web-apps/tensorboards/frontend
npm run serve > serve.log 2>&1 & npx wait-on http://localhost:4200
npm run ui-test-ci-all
65 changes: 65 additions & 0 deletions .github/workflows/twa_integration_test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: TWA Integration Test
on:
pull_request:
paths:
- components/crud-web-apps/tensorboards/**
- components/crud-web-apps/common/**
- releasing/version/VERSION
branches:
- main
- v*-branch
- notebooks-v1

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}
cancel-in-progress: true

env:
IMG: ghcr.io/kubeflow/notebooks/tensorboards-web-app
TAG: integration-test

jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Build TWA Image
run: |
cd components/crud-web-apps/tensorboards
make docker-build

- name: Install KinD
run: ./components/testing/gh-actions/install_kind.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While not directly related to changes introduced in this PR - given the AWS outage today - I am seeing issues trying to retrieve the kind binary referenced in install_kind.sh

➜ Downloads/ $ curl -vL -o kind "https://kind.sigs.k8s.io/dl/v0.22.0/kind-linux-amd64"
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* Host kind.sigs.k8s.io:443 was resolved.
* IPv6: 2600:1f18:16e:df01::259, 2600:1f18:16e:df01::258
* IPv4: 18.208.88.157, 98.84.224.111
*   Trying 18.208.88.157:443...
*   Trying [2600:1f18:16e:df01::259]:443...
* Immediate connect fail for 2600:1f18:16e:df01::259: No route to host
*   Trying [2600:1f18:16e:df01::258]:443...
* Immediate connect fail for 2600:1f18:16e:df01::258: No route to host
  0     0    0     0    0     0      0      0 --:--:--  0:01:09 --:--:--     0

It seems GitHub also hosts this binary and it available here:

  • https://github.com/kubernetes-sigs/kind/releases/download/v0.22.0/kind-linux-amd64

And I have confirmed its presently accessible:

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 6245k  100 6245k    0     0  17.4M      0 --:--:-- --:--:-- --:--:-- 17.4M

Should install_kind.sh be updated to use this alternative location?

Copy link
Author

@yehudit1987 yehudit1987 Oct 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this wondering depends on the answer to the question which of the two is more reliable in general?


- name: Create KinD Cluster
run: kind create cluster --config components/testing/gh-actions/kind-1-25.yaml

- name: Load Image into KinD Cluster
run: |
kind load docker-image "${IMG}:${TAG}"

- name: Install kustomize
run: ./components/testing/gh-actions/install_kustomize.sh

- name: Install Istio
run: ./components/testing/gh-actions/install_istio.sh

- name: Build & Apply manifests
run: |
cd components/crud-web-apps/tensorboards/manifests
kubectl create ns kubeflow

export CURRENT_IMAGE="${IMG}"
export PR_IMAGE="${IMG}:${TAG}"

# escape "." in the image names, as it is a special characters in sed
export CURRENT_IMAGE=$(echo "$CURRENT_IMAGE" | sed 's|\.|\\.|g')
export PR_IMAGE=$(echo "$PR_IMAGE" | sed 's|\.|\\.|g')

kustomize build overlays/istio \
| sed "s|${CURRENT_IMAGE}:[a-zA-Z0-9_.-]*|${PR_IMAGE}|g" \
| kubectl apply -f -

kubectl wait pods -n kubeflow -l app=tensorboards-web-app --for=condition=Ready --timeout=300s
41 changes: 41 additions & 0 deletions .github/workflows/twa_multi_arch_test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: TWA Multi-Arch Build Test
on:
pull_request:
paths:
- components/crud-web-apps/tensorboards/**
- components/crud-web-apps/common/**
- releasing/version/VERSION
branches:
- main
- v*-branch
- notebooks-v1

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event.number }}
cancel-in-progress: true

env:
IMG: ghcr.io/kubeflow/notebooks/tensorboards-web-app
PLATFORMS: linux/amd64,linux/ppc64le,linux/arm64/v8

jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup QEMU
uses: docker/setup-qemu-action@v3

- name: Setup Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build multi-arch images
uses: docker/build-push-action@v5
with:
context: components/crud-web-apps
file: components/crud-web-apps/tensorboards/Dockerfile
platforms: ${{ env.PLATFORMS }}
tags: ${{ env.IMG }}:${{ github.sha }}

Loading
Loading