Skip to content

Merge branch 'meshery:master' into master #262

Merge branch 'meshery:master' into master

Merge branch 'meshery:master' into master #262

name: Meshery End-to-End Tests with mesheryctl
on:
workflow_dispatch:
inputs:
profile_name:
description: "performance profile to use"
required: true
profile_filename:
description: "test configuration file"
required: false
patternfile_url:
description: "URL of the pattern file"
required: false
patternfile_name:
description: "name of the pattern file"
required: false
bats_test:
description: "run only bats suite test"
required: false
push:
branches:
- "master"
paths:
- "mesheryctl/**"
# scheduled to run at the 43rd minute of every 12th hour
schedule:
- cron: '43 */24 * * *'
jobs:
manual-bats:
name: Manual BATS Test
runs-on: ubuntu-24.04
if: ${{ (github.event_name == 'push' && github.repository == 'meshery/meshery') || (github.event_name == 'workflow_dispatch' && inputs.bats_test == 'true') }}
strategy:
fail-fast: false
matrix:
go: ['1.25']
k8s_version: ['v1.33.0', 'v1.34.3']
platform: ['kubernetes']
steps:
- name: Checkout Code
uses: actions/checkout@v6
- name: Set up Docker
uses: docker/[email protected]
- name: Setup BATS and BATS libs
id: setup-bats
uses: bats-core/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
- uses: actions/setup-go@v6
with:
go-version: ${{ matrix.go }}
- run: |
mkdir -p $HOME/.kube
mkdir -p $HOME/.minikube
sudo chown -R $USER $HOME/.kube
sudo chown -R $USER $HOME/.minikube
- name: Setup Kubernetes
uses: manusa/[email protected]
with:
minikube version: 'v1.37.0'
kubernetes version: ${{ matrix.k8s_version }}
driver: docker
- name: Run minikube tunnel
run: |
echo 'Running minikube tunnel'
minikube tunnel &> /dev/null &
shell: bash
- name: Get Date
id: date
run: echo "date=date +'%Y-%m-%d-%H.%M.%S'" >> $GITHUB_OUTPUT
- name: Build mesheryctl and start Meshery
run: |
make build && \
./mesheryctl system start --platform ${{ matrix.platform }} --skip-browser --skip-update
shell: bash
working-directory: ./mesheryctl
- name: Run mesheryctl end2end tests
run: |
bash run_tests.bash | tee bats.tap
shell: bash
working-directory: ./mesheryctl/tests/e2e
env:
MESHERY_PROVIDER_TOKEN: ${{ secrets.PROVIDER_TOKEN }}
MESHERY_PLATFORM: ${{ matrix.platform }}
BATS_LIB_PATH: ${{ steps.setup-bats.outputs.lib-path }}
E2E_HELPERS_PATH: "${{ github.workspace }}/mesheryctl/tests/e2e/helpers"
- name: Convert TAP to Allure results
if: ${{ !cancelled() && github.event_name == 'push' }}
working-directory: ./mesheryctl
run: |
node bats-to-allure.js tests/e2e/bats.tap
- name: Checkout QA
uses: actions/checkout@v6
if: ${{ !cancelled() && github.event_name == 'push' }}
with:
repository: meshery/qa
path: ./qa
token: ${{ secrets.GH_ACCESS_TOKEN }}
- name: Sync results with qa
if: ${{ !cancelled() && github.event_name == 'push' }}
working-directory: qa
run: |
make mesheryctl-results-sync MESHERYCTL_RESULTS_PATH=../mesheryctl/allure-results
- name: Commit & push to qa
if: ${{ !cancelled() && github.event_name == 'push' }}
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "[mesheryctl] Sync mesheryctl E2E Test Results - ${GITHUB_SHA}"
commit_options: "--signoff"
repository: qa
commit_user_name: meshery-ci
commit_user_email: [email protected]
env:
GITHUB_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
manual-test:
name: Manual e2e Test
runs-on: ubuntu-24.04
if: ${{ github.event_name == 'workflow_dispatch' && inputs.bats_test != 'true' }}
strategy:
fail-fast: false
matrix:
k8s_version: ['v1.33.0', 'v1.34.3']
platform: ['docker', 'kubernetes']
steps:
- name: Setup Kubernetes
uses: manusa/[email protected]
with:
minikube version: 'v1.37.0'
kubernetes version: ${{ matrix.k8s_version }}
driver: docker
- run: |
mkdir -p $HOME/.kube
mkdir -p $HOME/.minikube
sudo chown -R $USER $HOME/.kube
sudo chown -R $USER $HOME/.minikube
- name: Run minikube tunnel
run: |
echo 'Running minikube tunnel'
minikube tunnel &> /dev/null &
shell: bash
- name: Get Date
id: date
run: echo "date=date +'%Y-%m-%d-%H.%M.%S'" >> $GITHUB_OUTPUT
- name: Checkout Code
uses: actions/checkout@master
- name: Run Performance Tests
uses: layer5io/meshery-smp-action@master
with:
provider_token: ${{ secrets.PROVIDER_TOKEN }}
platform: ${{ matrix.platform }}
profile_name: ${{ github.event.inputs.profile_name }}
profile_filename: ${{ github.event.inputs.profile_filename }}
test_name: '${{ steps.date.outputs.date }}'
- name: Deploy Service Mesh
run: |
cat ~/auth.json
echo | mesheryctl adapter deploy meshery-istio --namespace istio-system -t ~/auth.json ISTIO
sleep 50
shell: '/bin/bash {0}'
- name: Apply Pattern
uses: layer5io/meshery-service-mesh-patterns-action@master
with:
provider_token: ${{ secrets.PROVIDER_TOKEN }}
platform: ${{ matrix.platform }}
pattern_url: ${{ github.event.inputs.pattern_url }}
pattern_file: ${{ github.event.inputs.pattern_file }}
scheduled-test:
name: Scheduled e2e Test
runs-on: ubuntu-24.04
if: ${{ github.event_name == 'schedule' && github.repository == 'meshery/meshery' }}
strategy:
fail-fast: false
matrix:
k8s_version: ['v1.33.0', 'v1.34.3']
platform: ['docker', 'kubernetes']
steps:
- name: Setup Kubernetes
uses: manusa/[email protected]
with:
minikube version: 'v1.37.0'
kubernetes version: ${{ matrix.k8s_version }}
driver: docker
- name: Run minikube tunnel
run: |
echo 'Running minikube tunnel'
minikube tunnel &> /dev/null &
shell: bash
- name: Get Date
id: date
run: echo "date=(date +'%Y-%m-%d-%H.%M.%S')" >> $GITHUB_OUTPUT
- name: Checkout Code
uses: actions/checkout@master
- name: Run Performance Tests
uses: layer5io/meshery-smp-action@master
with:
provider_token: ${{ secrets.PROVIDER_TOKEN }}
platform: ${{ matrix.platform }}
profile_name: integration-e2e-workflow
profile_filename: integration-test-config.yaml
test_name: '${{ steps.date.outputs.date }}'
- name: Deploy Service Mesh
run: |
echo | mesheryctl adapter deploy meshery-istio --namespace istio-system -t ~/auth.json ISTIO
sleep 50
shell: '/bin/bash {0}'
# - name: Apply BookInfo Pattern
# uses: layer5io/mesheryctl-service-mesh-patterns-action@master
# with:
# provider_token: ${{ secrets.PROVIDER_TOKEN }}
# platform: ${{ matrix.platform }}
# pattern_url: https://raw.githubusercontent.com/service-mesh-patterns/service-mesh-patterns/master/samples/bookInfoPattern.yaml
- name: Apply Kubernetes Metrics Service Pattern
uses: layer5io/mesheryctl-service-mesh-patterns-action@master
with:
provider_token: ${{ secrets.PROVIDER_TOKEN }}
platform: ${{ matrix.platform }}
pattern_url: https://raw.githubusercontent.com/meshery/meshery.io/master/catalog/57f7230d-015b-4892-9042-cd1ea97fcb30.yaml
- name: Load "Serve An LLM With Multiple GPUs In GKE" design
uses: layer5io/mesheryctl-service-mesh-patterns-action@master
with:
provider_token: ${{ secrets.PROVIDER_TOKEN }}
platform: ${{ matrix.platform }}
pattern_url: https://raw.githubusercontent.com/meshery/meshery.io/master/catalog/9d3b33bf-eaf6-4d06-9dd6-64aa725ab383.yaml