Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test-change #86

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
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
27 changes: 27 additions & 0 deletions .github/workflows/chainsaw.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Chainsaw

on:
pull_request:
branches:
- main

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

jobs:
build:
name: Chainsaw tests
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Setup cluster
run: make

- name: Install chainsaw
uses: kyverno/action-install-chainsaw@v0.2.5

- name: Run chainsaw tests
run: chainsaw test ./tests/04-test-the-system
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Kyverno Keptn Workshop

Please find the full Workshop Documentation here: https://heckelmann.github.io/kyverno-keptn-workshop/
Please find the full Workshop Documentation here: https://heckelmann.github.io/kyverno-keptn-workshop/

![Banner](docs/assets/00-banner.jpg)
59 changes: 59 additions & 0 deletions tests/04-test-the-system/chainsaw-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/kyverno/chainsaw/main/.schemas/json/test-chainsaw-v1alpha1.json
apiVersion: chainsaw.kyverno.io/v1alpha1
kind: Test
metadata:
name: dev-app
spec:
namespace: argocd
steps:
- try:
- assert:
timeout: 10m
resource:
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: demo-app-dev
status:
health:
status: Healthy
sync:
status: Synced
- assert:
timeout: 5m
resource:
apiVersion: lifecycle.keptn.sh/v1
kind: KeptnApp
metadata:
name: demo-app
namespace: demo-app-dev
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/kyverno/chainsaw/main/.schemas/json/test-chainsaw-v1alpha1.json
apiVersion: chainsaw.kyverno.io/v1alpha1
kind: Test
metadata:
name: prod-app
spec:
namespace: argocd
steps:
- try:
- assert:
timeout: 10m
resource:
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: demo-app-prod
status:
health:
status: Healthy
sync:
status: Synced
- assert:
timeout: 5m
resource:
apiVersion: lifecycle.keptn.sh/v1
kind: KeptnApp
metadata:
name: demo-app
namespace: demo-app-prod