On this directory you can find some python scripts used to help with some repetitive tasks.
Today we have these scripts:
The common.py
script defines some common functions for the scripts.
Utilitary script used to retrieve all images that can be built on this repo, there is possible to retrieve the community image list:
$ python list-images.py
The manage-kogito-version script will help when we need to update the current version due a new release.
The manage-kogito-version.py
has one dependency that needs to be manually installed:
$ pip install -U ruamel.yaml
This script has also a dependency on common.py
.
Its default behavior is pretty simple:
$ python manage-kogito-version.py --bump-to 1.0.0
This will set images' version, artifacts reference version and examples reference to 1.0.0.
You can also set a custom version for artifacts and/or a custom reference to the kogito-examples repository:
$ python manage-kogito-version.py --bump-to 0.10.2 --artifacts-version 0.10.5 --examples-ref 0.10.x
The command above will update all the needed files to the given version(s).
These changes include updates on
This script will help you while building images and test in a local OpenShift Cluster. It requires you to already have images built in your local registry with the tag following the patter: X.Z, e.g. 0.10:
docker.io/apache/incubator-kie-kogito-jobs-service-ephemeral:0.10
The Makefile has an option to do it, it can be invoked as the following sample:
$ make push-local-registry REGISTRY=docker-registry-default.apps.test.cloud NS=test-1
Where NS stands for the namespace where the images will be available.
To execute the script directly:
$ /bin/sh scripts/push-local-registry.sh my_registry_address 0.10 my_namespace
Staging images are the release candidates which are pushed mainly after big changes that has direct impact on how the images will behave and also when new functionality is added.
The script updates the version on:
The push-staging.py
has a few dependencies that probably needs to be manually installed:
$ pip install -U docker yaml $ pip install -U ruamel.yaml
This script is called as the last step of the make push-staging
command defined on the Makefile.
It will look for the current RC images available on quay.io to increase the rc tag accordingly then push the new tag so it can be tested by others. If there is no need to update the tag, there is the option to override it, just set the flag “-o”.
The update-repository
script allows you to change some build & test information in the repository.
The update-repository.py
has some dependencies that needs to be manually installed:
$ pip install -U ruamel.yaml
$ python update-repository.py --repo-url 'https://maven-repository.mirror.com/public'
This will add this repository as an extra repository for artifacts to be retrieved from into the behave tests, next to the default JBoss repository.
You can also completely replace the main Jboss repository:
$ python update-repository.py --repo-url 'https://maven-repository.mirror.com/public' --replace-jboss-repo
$ python update-repository.py --artifacts-version 1.0.0
This will set the default artifacts version.
$ python update-repository.py --quarkus-platform-version 3.8.6
This will set the image quarkus version to 3.8.6.
$ python update-repository.py --examples-uri https://github.com/<yournamespace>/kogito-examples --examples-ref 1.0.0
This will update the examples uri and/or the ref for the tests.