GithubHelp home page GithubHelp logo

isabella232 / microsoft-flux-conformance Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 0.0 97 KB

Conformance Testing for the Microsoft.Flux extension for cluster deployments of Flux in Azure

License: MIT License

Dockerfile 1.74% Shell 13.42% Python 82.98% Makefile 1.86%

microsoft-flux-conformance's Introduction

Microsoft.Flux Conformance Testing

Build Status

Development

  1. Setup a virtual environment for Python
python -m venv env
source env/bin/activate
  1. Create a setup-test.sh file in the format of setup-test.template
export TENANT_ID=<TENANT-ID>
export CLIENT_ID=<CLIENT-ID>
export OBJECT_ID=<OBJECT-ID>
export CLIENT_SECRET=<CLIENT-SECRET>
export SUBSCRIPTION_ID=<SUBSCRIPTION-ID>
export RESOURCE_GROUP=<RESOURCE-GROUP>
export CLUSTER_NAME=conformance-testing-arc
export LOCATION=eastus
export RESULTS_DIR=./results
export CUSTOM_KUBECONFIG=~/.kube/config
export NUM_TESTS=2
export CA_CERT_FILE=./src/file/https-ca.cer
  1. Source the setup-test.sh file to override the values in the Makefile
source setup-test.sh

To be able to properly run the tests, you will need to create an SPN that has permission to operate over whichever resource group that you plan to create

  1. Run the following command to setup the cluster and install the extension
make setup

You can take a look at the Makefile to see the exact configuration and the steps that are taken to configure the cluster

  1. Run the test command to validate the pytest tests that you have created work
make test

Notes

Running Conformance Tests on OpenShift Clusters

In order to run this conformance test suite on OpenShift clusters, you will need to add the following security context constraints to the cluster

NS="flux-system"
oc adm policy add-scc-to-user nonroot system:serviceaccount:$NS:kustomize-controller
oc adm policy add-scc-to-user nonroot system:serviceaccount:$NS:helm-controller
oc adm policy add-scc-to-user nonroot system:serviceaccount:$NS:source-controller
oc adm policy add-scc-to-user nonroot system:serviceaccount:$NS:notification-controller
oc adm policy add-scc-to-user nonroot system:serviceaccount:$NS:image-automation-controller
oc adm policy add-scc-to-user nonroot system:serviceaccount:$NS:image-reflector-controller
oc adm policy add-scc-to-user privileged system:serviceaccount:nginx:nginx-nginx-nginx-ingress-controller
oc adm policy add-scc-to-user nonroot system:serviceaccount:redis:default

The flux controllers and the nginx and redis deployments need additional permissions on the OpenShift clusters in order to come up and run properly.

microsoft-flux-conformance's People

Contributors

jonathan-innis avatar microsoftopensource avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.