Skip to content

Commit

Permalink
Merge pull request #10 from navendu-pottekkat/update-docs/navendu-pot…
Browse files Browse the repository at this point in the history
…tekkat
  • Loading branch information
DelusionalOptimist authored Sep 30, 2021
2 parents 91d47ce + af99f58 commit 1a53551
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 37 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@

# Dependency directories (remove the comment below to include it)
# vendor/

.vscode/*
75 changes: 47 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,64 +1,83 @@
# Meshery SMP Action
This repository is used for storing a GitHub action for performing SMP tests using Meshery
# Meshery - SMP GitHub Action

## Inputs
```yaml
# token to connect with the remote provider
provider_token:
description: "Provider token to use. NOTE: value of the 'token' key in auth.json"
required: true
GitHub Action to run SMP Performance Benchmarks on CI/CD pipelines.

[Meshery](https://meshery.io/) is the canonical implementation of the [Service Mesh Performance specification](https://smp-spec.io/).

## Learn More

- [Performance Management in Meshery](https://docs.meshery.io/functionality/performance-management)
- [Guide: Running Performance Tests in Meshery](https://docs.meshery.io/guides/performance-management)
- [Supported Service Meshes](https://docs.meshery.io/service-meshes)

## Usage

See [action.yml](action.yml)

# platform to deploy meshery
platform:
description: "Platform to deploy meshery on. Possible values: docker, kubernetes"
default: docker
You can use this action by defining your test configuration in a performance profile in Meshery or write your test configurations in SMP compatible format ([see example](#smp-compatible-test-configuration-file)).

# SUPPLY EITHER "profile_filename" or profile_name
You can then pass in either of these to the action to run a performance test.

# name of the file storing the performance profile (keep in .github)
profile_filename:
description: "Name of the file containing SMP profile"
The results of the tests are updated on the Performance Management dashboard in Meshery.

# name of the prformance profile to use
profile_name:
description: "Name of the performance profile"
See [Performance Management with Meshery](https://docs.meshery.io/guides/performance-management) for detailed instructions on setting up Meshery and authenticating the GitHub Action.

## SMP Compatible Test Configuration File

```yaml
smp_version: v0.0.1
id:
name: Istio Performance Test
labels: {}
clients:
- internal: false
load_generator: fortio
protocol: 1
connections: 2
rps: 10
headers: {}
cookies: {}
body: ""
content_type: ""
endpoint_urls:
- http://localhost:2323/productpage
duration: "30m"
```
## Sample configuration
```yaml
name: Testing SMP action
name: Meshery SMP Action
on:
push:
branches:
'perf'
'master'

jobs:
job1:
name: Run Performance Test
performance-test:
name: Performance Test
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v2
with:
ref: 'perf'

- name: Deploy k8s
- name: Deploy k8s-minikube
uses: manusa/[email protected]
with:
minikube version: 'v1.21.0'
kubernetes version: 'v1.20.7'
driver: docker

- name: Performance test
- name: Run Performance Test
uses: layer5io/meshery-smp-action@master
with:
provider_token: ${{ secrets.PROVIDER_TOKEN }}
platform: docker
profile_name: demo
profile_name: istio-soak-test
```
<div>&nbsp;</div>
## Join the service mesh community!
<a name="contributing"></a><a name="community"></a>
Expand Down
22 changes: 13 additions & 9 deletions action.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,29 @@
name: "Service Mesh Performance Testing with Meshery"
description: "Validate SMP specification using Meshery"
name: "Performance Testing with Meshery"
description: "Run performance tests in SMP format with Meshery"
author: "Layer5"

inputs:
# token to connect with the remote provider
# token to authenticate with Meshery
# see: https://docs.meshery.io/guides/performance-management#running-performance-benchmarks-in-your-pipelines
provider_token:
description: "Provider token to use. NOTE: value of the 'token' key in auth.json"
required: true

# platform to deploy meshery
# platform to deploy Meshery to
platform:
description: "Platform to deploy meshery on. Possible values: docker, kubernetes"
description: "Platform to deploy Meshery to. Allowed values: docker, kubernetes"
default: docker

# SUPPLY EITHER "profile_filename" or profile_name
# provide either a test configuration file or a performance profile name

# name of the file storing the performance profile (keep in .github)
# name of the test configuration file written in SMP compatible format
# see: https://docs.meshery.io/guides/performance-management#running-performance-benchmarks-through-mesheryctl
# store this file in the .github folder in your repository
profile_filename:
description: "Name of the file containing SMP profile"
description: "Name of the test configuration file"

# name of the prformance profile to use
# name of the performance profile to use to run tests
# see: https://docs.meshery.io/functionality/performance-management#performance-profiles
profile_name:
description: "Name of the performance profile"

Expand Down

0 comments on commit 1a53551

Please sign in to comment.