bonfire cheat sheet - cloudigrade/cloudigrade GitHub Wiki
Since the OpenShift ephemeral cluster is only "ephemeral" in name and its number of available namespaces is relatively small, developers should consciously reserve and release namespaces as their needs require.
Reserve a namespace
By default, namespaces are reserved for one hour and do not use managed Kafka. However, for development or testing purposes that may not be sufficient. The following command reserves a namespace for 8 hours and uses the real managed Kafka configuration.
NAMESPACE=$(bonfire namespace reserve --pool real-managed-kafka --duration "8h")
oc project "${NAMESPACE}"
This new NAMESPACE
environment variable contains the ephemeral cluster namespace/project we will be using (e.g. ephemeral-6sc0an
) and will be used in subsequent example commands.
bonfire namespace list --mine
NAME RESERVED ENV STATUS APPS READY REQUESTER EXPIRES IN
---------------- ---------- ---------- ----------- ----------- ------------
ephemeral-6sc0an true ready 0/0 abellotti 7h59m13s
Extend a reservation time
If your remaining namespace reservation time is almost finished and you still need to do additional work, you can extend your reservation as follows:
First, check to see how much time left you have, that is shown in the EXPIRES IN
column:
bonfire namespace list --mine
NAME RESERVED ENV STATUS APPS READY REQUESTER EXPIRES IN
---------------- ---------- ---------- ----------- ----------- ------------
ephemeral-6sc0an true ready 6/6 abellotti 1h03m13s
You can extend your reservation by a number of hours, with the following example extending the reservation by 4 hours:
bonfire namespace extend --duration "4h" ${NAMESPACE}
You can now see the extended expiration time as follows:
bonfire namespace list --mine
NAME RESERVED ENV STATUS APPS READY REQUESTER EXPIRES IN
---------------- ---------- ---------- ----------- ----------- ------------
ephemeral-6sc0an true ready 6/6 abellotti 5h02m57s
Release a namespace
When you're finished using it, release your namespace so the resources can be freed and made available for other users in the cluster:
bonfire namespace release ${NAMESPACE}