jeudi 1 février 2018

Testing python app in openshift

I'm using a local openshift (minishift) v3.7.0 cluster to deploy a python app. I'm trying without success to test it using pytest and openshift jenkins instance. My current workflow :

  • Launch an instance of the app with oc new-app mygitrepo -e APP_SCRIPT='myapp.py' --strategy=source
  • Launch the tests by using oc new-app mygitrepo --strategy=pipeline
    • I have a Jenkinsfile in my app repo creating a job (with the app image) launching pytest.

The main problem is that the job is failing whatever I'm doing. The other point is that launching the app twice is not satisfying.

So what is the best way to launch tests before deployment on a python way with Jenkins on openshift?

Aucun commentaire:

Enregistrer un commentaire