vania-janet/multiturn-rag-retrieval-data huggingface dataset:
Building Docker images 

You can build all of the Docker images in the containerize stage that you need. If you wish to override the default built-in GPG Image signing for those images, you need to let the pipeline be aware of these images.



 Adding image artifacts 

You can add image artifacts by using the pipelinectl interface. In the containerize stage, add the images as artifacts to the pipeline:

save_artifact <image-alias> type=image "name=${IMAGE}" "digest=${DIGEST}" [<prop>=<value>]

Where the value of name must be a fully qualified image name, for example: your-docker-repository.namespace/imagename:imagetag and digest must be the sha256 digest of the image, for example, sha256:c43e802dcc7485590b54614006ced9338d5bd9a045115c89d5570bb95eeb52d9.

<image-alias> can be any string, its purpose to provide a human-readable name for your image among the other artifacts. You can add any properties to the artifact, like tags, timestamp, etc.

The type, name, and digest fields are required!



 Example 

save_artifact service type=image name="${SERVICE_IMAGE}" digest="${SERVICE_IMAGE_DIGEST}" tags="${SERVICE_IMAGE_TAGS}"

save_artifact service_debug type=image "name=${SERVICE_DEBUG_IMAGE}" "digest=${SERVICE_DEBUG_IMAGE_DIGEST}"

By using this interface, the default built-in GPG Image signing will be able to pick up these images and process them.







 Loading image artifacts 

At the end of the pipeline in the release stage, you can access these artifacts using the pipelinectl interface:

list_artifacts
load_artifact <image-alias> <property>

list_artifacts lists the image aliases available, where <property> is any property that you or the pipeline added previously. Using these together you can iterate over your artifacts, for example:
ibmcloud cr image-rm 

Delete one or more specified images from Container Registry. You can reference the image that you want to delete either by [digest](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewoverview_elements_digest) or by [tag](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewoverview_elements_tag).

Where multiple tags exist for the same image digest within a repository, the ibmcloud cr image-rm command removes the underlying image and all its tags. If the same image exists in a different repository or namespace, that copy of the image is not removed. If you want to remove a tag from an image and leave the underlying image and any other tags in place, use the [ibmcloud cr image-untag](https://cloud.ibm.com/docs/cli?topic=cli-containerregclibx_cr_image_untag) command.

If you want to restore a deleted image, you can list the contents of the trash by running the [ibmcloud cr trash-list](https://cloud.ibm.com/docs/cli?topic=cli-containerregclibx_cr_trash_list) command and restore a selected image by running the [ibmcloud cr image-restore](https://cloud.ibm.com/docs/cli?topic=cli-containerregclibx_cr_image_restore) command.

ibmcloud cr image-rm IMAGE [IMAGE...]



 Prerequisites 

To find out about the required permissions, see [Access roles for using Container Registry](https://cloud.ibm.com/docs/Registry?topic=Registry-iamaccess_roles_using).





 Command options 

IMAGE
: The name of the image that you want to delete. You can delete multiple images at the same time by listing each image in the command with a space between each name.
CLI - 0.5.2 (deprecated) 

You can use the Key Protect CLI plug-in to manage keys in your instance of Key Protect.

To install the Key Protect CLI plug-in, see [Setting up the CLI](https://cloud.ibm.com/docs/key-protect?topic=key-protect-set-up-cli).

When you log in to the [IBM Cloud CLI](https://cloud.ibm.com/docs/cli?topic=cli-getting-started), you're notified when updates are available. Be sure to keep your CLI up-to-date so that you can use the commands and flags that are available for the Key Protect CLI plug-in.



 Notes 



 Previous version 

The documentation for version 0.5.2 does not include deprecated commands.

[Version 0.3.9](https://cloud.ibm.com/docs/key-protect?topic=key-protect-cli-reference-039) has documentation for deprecated commands.

All deprecated commands work in versions 0.4.0 and 0.5.2. That is, version 0.5.2 is backwards compatible with versions 0.3.9 and 0.4.0. For example, you can issue the kp create command even though it's deprecated in version 0.5.2.

The intent is to remove support for deprecated commands in the next CLI version, which is anticipated the end of September, 2020.





 Examples 

All commands have an Example section, which shows how to use the command in the context of a workflow.

The examples assume you have [openssl](https://www.openssl.org/) and [jq](https://stedolan.github.io/jq/) installed.

The examples use the exported Key Protect instance environment variable instead of the -i parameter.

 export the Key Protect instance id
$ export KP_INSTANCE_ID=390086ac-76fa-4094-8cf3-c0829bd69526
Log in to IBM Cloud by running the ibmcloud login command.
2. List the images in the trash by running the following command:

ibmcloud cr trash-list

A table is displayed that shows the items in the trash. The table shows the digest, the days until expiry, and the tags for that digest.
3. Note the digest for the image that you want to restore.
4. Run the following command to restore the image to your repository. Where <dns> is the [domain name](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewoverview_elements_domain_name), <namespace> is the [namespace](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewoverview_elements_namespace), <repo> is the [repository](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewoverview_elements_repository), and <digest> is the [digest](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewoverview_elements_digest) of the image that you want to restore.

ibmcloud cr image-restore <dns>/<namespace>/<repo>@<digest>

If some tags aren't restored, see [Why aren't all the tags restored when I restore by digest?](https://cloud.ibm.com/docs/Registry?topic=Registry-troubleshoot-image-restore-digest) for assistance.

In your live repository, you can pull the image by digest. If you run the [ibmcloud cr image-digests](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_digests) command, the image shows in the output.







 Restoring images by tag 

When you restore an image by tag, only that specific tag is moved out of the trash into your live repository.

To restore an image by tag from the trash, complete the following steps:



1.
If you want to restore a deleted image, you can list the contents of the trash by running the [ibmcloud cr trash-list](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_trash_list) command and restore a selected image by running the [ibmcloud cr image-restore](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_restore) command.

To delete an image by using the CLI, complete the following steps:



1. Log in to IBM Cloud by running the ibmcloud login command.
2. To delete an image, run the following command, where IMAGE is the name of the image that you want to remove, in the format repository@digest or repository:tag. If a tag is not specified in the image name, the image tagged latest is deleted by default. You can delete multiple images by listing each private IBM Cloud registry path in the command with a space between each path.

ibmcloud cr image-rm IMAGE

To find the names of your images, run ibmcloud cr image-list. Combine the content of the Repository column (repository) and Tag column (tag) separated by a colon (:) to create the image name in the format repository:tag. To identify your image by digest, run the ibmcloud cr image-digests command. Combine the content of the Repository column (repository) and the Digest column (digest) separated by an at (@) symbol to create the image name in the format repository@digest. If the list images command times out, see [Why is it timing out when I list images?](https://cloud.ibm.com/docs/Registry?topic=Registry-troubleshoot-image-timeout) for assistance.
3. Verify that the image was deleted by running the following command, and check that the image does not show in the list.

ibmcloud cr image-list







 Deleting images from your private repository in the console 

You can delete unwanted images and all their tags from your private IBM Cloud image repository by using the IBM Cloud console.
After version 2.0, images no longer include grunt or python. If these tools are required for your build, you can install them manually. To install grunt, run npm install -g grunt-cli. Make sure that you don't change the Node.js version after you install grunt. To install python on a 2.x vbi, run apt-get -qq update && apt-get -qq install -y python. If you are using a 3.x vbi, you can use yum update -yq && yum install -yq python3-pip.

Images are available on the IBM Cloud Container Registry. To list these hosted images, run the ibmcloud cr images --restrict continuous-delivery command when you target the global IBM Cloud Container Registry.



Table 1. Mapping between versioned based images and IBM Cloud Registry versions with sha256 values

 Base image version IBM Cloud Container Registry version sha256 value 

 3.25 icr.io/continuous-delivery/pipeline/pipeline-base-ubi:3.25 sha256:dd2000b525336acd00e9b95b74f15696797764725adbb25fa720e9431d558cbf 
 3.24 icr.io/continuous-delivery/pipeline/pipeline-base-ubi:3.24 sha256:7a52b892ae7704a7b6c4cf03a292356240305c0d7bc9c275d10df19d12db99c5 
 3.23 icr.io/continuous-delivery/pipeline/pipeline-base-ubi:3.23 sha256:e62fe158ebc7d875a0be5263da6872250fd8038b00cef0aada4b9f14f06dd827
If you run the [ibmcloud cr image-digests](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_digests) command, the image shows in the output.







 Restoring images by tag 

When you restore an image by tag, only that specific tag is moved out of the trash into your live repository.

To restore an image by tag from the trash, complete the following steps:



1. Log in to IBM Cloud by running the ibmcloud login command.
2. List the images in the trash by running the following command:

ibmcloud cr trash-list

A table is displayed that shows the items in the trash. The table shows the digest, the days until expiry, and the tags for that digest.
3. For the image that you want to restore, make a note of the digest up to, but not including, the at sign (@). This part of the digest is <dns>/<namespace>/<repo>, where <dns> is the domain name, <namespace> is the namespace, and <repo> is the repository.
4. For the image that you want to restore, make a note of the tag, <tag>.
5. Run the following command to restore the image to your repository, where <dns>/<namespace>/<repo> is the name of the image that you want to restore and <tag> is the tag.

ibmcloud cr image-restore <dns>/<namespace>/<repo>:<tag>

In your live repository, you can pull the image by tag.

If you get an error when you're restoring an image that says that the tagged image exists, see [Why do I get an error when I'm restoring an image?](https://cloud.ibm.com/docs/Registry?topic=Registry-troubleshoot-image-restore) for assistance.

If you run the ibmcloud cr trash-list command, the digest and any other tags show in the output, but the tag is no longer displayed.
In the previous example, you can see that only one image is in the same repository as the manifest list sha256:865b0c35e6da393b8e80b7e3799f777572399a4cff047eb02a81fa6e7a48ed4b and therefore, the manifest list is referencing another image sha256:1d71e323557502cc78ee6c237331a09b0c33ba59c14e5f683da3b1c6218779cc that does not currently exist in the repository.

You can resolve this issue by using one of the following options, following on from the previous example.



* If the missing image exists elsewhere in the registry, you can use the [ibmcloud cr image-tag](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_tag) command to move the image to the same repository.



1. To detect if the missing digest exists elsewhere in the registry, run the following command.

ibmcloud cr digests --format '{{if eq .Digest "sha256:1d71e323557502cc78ee6c237331a09b0c33ba59c14e5f683da3b1c6218779cc"}}{{.Repository}}@{{.Digest}}{{end}}'
icr.io/myrepo2/image2@sha256:1d71e323557502cc78ee6c237331a09b0c33ba59c14e5f683da3b1c6218779cc
2. If the previous command returns an image, you can copy it to the same repository as the manifest list.
* Step 8 [Mirroring the images to the intermediary container registry](https://www.ibm.com/docs/en/cloud-paks/cp-data/4.0?topic=registry-mirroring-images-intermediary-containerpreinstall_container_registry_air_gapped__mirror-to-target) of Mirroring images with an intermediary container registry



Each additional step is unique to the model that is being installed. If you install more than one of the new models, issue the indicated command for each model that you are installing.



* For the Chinese telephony model (zh-CN_Telephony):

echo 'cp.icr.io,cp/watson-speech/zh-cn-telephony,2022-01-05-405models,sha256:52af6dfccd64ccd81b409936442a51a71f4ee96d980e1fc6a343a05bd4ed7fbc,IMAGE,linux,x86_64,"",0,CASE,"",""' >> $CASE_PATH/ibm-watson-speech-4.0.5-images.csv
* For the Latin American Spanish telephony model (es-LA_Telephony):

echo 'cp.icr.io,cp/watson-speech/es-la-telephony,2022-01-05-405models,sha256:58e8c04abe9659472e89bf0778b7dc66e0ddceb4ea18d9d3e048a08c72125ea2,IMAGE,linux,x86_64,"",0,CASE,"",""' >> $CASE_PATH/ibm-watson-speech-4.0.5-images.csv
* For the Australian English multimedia model (en-AU_Multimedia):
From the list of templates, click the image template name that you want to update.
3. On the Image Template Details page, select the Enabled checkbox under the Cloud-init heading, and click Update.



If your image is encrypted, the Cloud-init checkbox is already selected by default since encrypted images must be cloud-init enabled.





 Work with an image template that was created from a cloud-init provisioned virtual server 

Cloud-init typically runs only one time. However, if you provision a virtual server from a cloud-init enabled image and later create an image template from that virtual server, the UUID is recorded. If that image template is used to create another virtual server, cloud-init runs again.





 Create image templates that are cloud-init enabled 

For information about configuring images, see [cloud-init documentation](https://cloudinit.readthedocs.io/en/latest/).

For more information about data sources, see [Data sources](http://cloudinit.readthedocs.io/en/latest/topics/datasources.html). IBM Cloud cloud-init images are created for the environment by using the [Config Drive](http://cloudinit.readthedocs.io/en/latest/topics/datasources/configdrive.html) Version 2 data source to supply the metadata.



 Linux requirements 

Linux images that are cloud-init enabled have the following requirements:



* Cloud-init version 0.7.7 or greater is required.
* Cloud-init image is configured to use SSH for logging in to your virtual server instance.



The following example cloud.cfg file shows settings that are used in a Red Hat Enterprise Linux 7 deployment. These settings differ from the default settings in the cloud-init installation package on Red Hat Enterprise Linux 7.

 cat /etc/cloud/cloud.cfg
 Configure the Datasource for both instances
datasource_list: [ ConfigDrive ]

user: root
ssh_pwauth: True
disable_root: False
Check the [command reference](https://cloud.ibm.com/docs/devsecops?topic=devsecops-devsecops-pipelinectlsave_artifact) for exact usage information.

Required fields:



* name
The artifact name. For example, for an image include registry, namespace, and image (example: us.icr.io/team-images/service).
* digest
The artifact digest (example: sha256:a2292ed2b82c7a51d7d180c3187dbb0f7cc9ab385a68484c4f117e994acd6192).
Remove the tag from the existing image in your live repository by running the [ibmcloud cr image-untag](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_untag) command. You can then restore the required image from the trash by running the [ibmcloud cr image-restore](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_restore) command with the option <repo>@<digest>, which restores the digest and its tags to the live repository. For more information, see [Restoring images by digest](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_images_registry_images_restore_digest). Alternatively, you can run the [ibmcloud cr image-tag](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_tag) command and use the restored digest as the source image.

In your live repository, you can pull the image by digest. If you run the [ibmcloud cr image-digests](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_digests) command, the image shows in the output.
* IMAGE2: ID or name of the image.
* --output: Specify output format, only JSON is supported. One of: JSON.
* --force, -f: Force the operation without confirmation.
* -q, --quiet: Suppress verbose output.



--------------------







 ibmcloud is image-export-job 

View details of an image export job.

ibmcloud is image-export-job IMAGE JOB [--output JSON] [-q, --quiet]



 Command examples 



* ibmcloud is image-export-job 72251a2e-d6c5-42b4-97b0-b5f8e8d1f479 6451a2e-d6c5-42b4-97b0-b5f8e8d1f479
* ibmcloud is image-export-job my-image my-export-job







 Command options 



* IMAGE: ID or name of the image.
* JOB: ID or name of the image export job.
* --output: Specify output format, only JSON is supported. One of: JSON.
* -q, --quiet: Suppress verbose output.



--------------------







 ibmcloud is image-export-jobs 

List all export jobs of an image.

ibmcloud is image-export-jobs IMAGE [--output JSON] [-q, --quiet]



 Command examples 



* ibmcloud is image-export-jobs 72251a2e-d6c5-42b4-97b0-b5f8e8d1f479
* ibmcloud is image-export-jobs my-image







 Command options 



* IMAGE: ID or name of the image.
* --output: Specify output format, only JSON is supported. One of: JSON.
* -q, --quiet: Suppress verbose output.
To find out which images are in the trash, run the [ibmcloud cr trash-list](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_trash_list) command.

You can restore images by running the [ibmcloud cr image-restore](https://cloud.ibm.com/docs/Registry?topic=Registry-containerregclibx_cr_image_restore) command. You can use the following options:



* <repo>@<digest>, which restores the digest and all its tags in the repository that aren't already in the live repository, see [Restoring images by digest](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_images_registry_images_restore_digest).
* <repo>:<tag>, which restores the tag, see [Restoring images by tag](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_images_registry_images_restore_tag).





 Restoring images by digest 

When you restore an image by digest, the digest is copied from the trash into your live repository, and all the tags for the digest in the repository are restored. The digest continues to show in the trash because a copy is restored.

To restore an image by digest from the trash, complete the following steps:



1. Log in to IBM Cloud by running the ibmcloud login command.
2. List the images in the trash by running the following command:

ibmcloud cr trash-list

A table is displayed that shows the items in the trash. The table shows the digest, the days until expiry, and the tags for that digest.
3. Note the digest for the image that you want to restore.
4. Run the following command to restore the image to your repository.
Working with image templates 



  Before you begin 

First, go to the devices menu and make sure that you have the correct account permissions to complete the tasks.



*  Go to your console's device menu. For more information, see [Navigating to devices](https://cloud.ibm.com/docs/virtual-servers?topic=virtual-servers-navigating-devices).
*  Make sure that you have any necessary account permissions and device access. Only the account owner, or a user with the Manage Users classic infrastructure permission, can adjust the permissions.



For more information about permissions, see [Classic infrastructure permissions](https://cloud.ibm.com/docs/account?topic=account-infrapermission) and [Managing device access](https://cloud.ibm.com/docs/virtual-servers?topic=virtual-servers-managing-device-access).





  Accessing image templates 

Complete the following steps to access image templates in your console.



1.  From the Devices menu, select Manage > Images.
2.  On the Image Templates screen, you see all of the private images that are associated with the account. Any interactions with private images happen here. You can also access public images by clicking the Private Images drop-down selector and choosing Public Images instead.



For more information about image templates, see [Getting started with image templates](https://cloud.ibm.com/docs/image-templates?topic=image-templates-getting-started-with-image-templatesgetting-started-with-image-templates).
If this flag is set --file flag is ignored. 
 --output or -o Optional Returns the command-line output in JSON format. Currently only JSON file format is supported. 
 --json or -j Deprecated Prints the output in the JSON format. 





 Update file template in JSON format 

You can create the JSON as shared in the example.json file for workspace update and pass the file path along with the file name in --file flag. The description of all the parameters of example.json is described in the table.

You need to replace the <...> placeholders with the actual values. For example, "<workspace_name>" as "testworkspace".

example.json:

{
"name": "<workspace_name>",
"type": "<terraform_version>",
"description": "<workspace_description>",
"tags": [],
"resource_group": "<resource_group>",
"workspace_status": {
"frozen": "<true_or_false>"
},
"template_repo": {
"url": "<source_repo_url>"
},
"template_data": [
{
"folder": ".",
"type": "<terraform_version>",
"env_values":
{
"VAR1":"<val1>"
},
{
"VAR2":"<val2>"
}
],
"variablestore":
{
"name": "<variable_name1>",
"value": "<variable_value1>",
"type": "<variable_type1>",
"secure": true,
"use_default": true },
{
"name": "<variable_name2>",
"value": "<variable_value2>",