vania-janet/multiturn-rag-retrieval-data huggingface dataset:
Promote to further environments 

Promotion and deployment can happen from any branch to another one.





 Inventory landscape 

The current, deployed state holds the content to deploy to an environment. Every promoted commit in the target branches contains the relevant pipeline run ID and Change Request ID, as a tag. Some commits can have multiple tags, such as when a failed deployment is run again. The Inventory stores each piece of information to replay the deployments.

Zoom

![Inventory landscape](https://cloud.ibm.com/docs-content/v1/content/5eb88a2575e30e316dbb83829c7f4c8b1ddbc67c/devsecops/images/devsecops-inventory-landscape.svg)

Figure 1. Inventory landscape



 Use of tags 



* latest: Tags the current, successfully deployed and concluded state of the inventory on a branch.
* pipeline run id: Tags the most recent inventory state in the branch, with the pipeline run ID or the build number of the actual deployment. You can use this information to refer to the actual inventory point hash in the branch history so that when parallel deployments are triggered you avoid inventory content overlapping.
* change request id: Optional. Tags the current state. Change request IDs are historically represented and tracked in the inventory.









 Single target - multiple region setup 

The single target - multiple region setup is an iteration on this model where multiple latest tags for a single target environment are introduced. This model allows multiple continuous pipelines to work on the same target for different types of use cases.

For example, you can use the same target environment for multiple regions (such as us-south and eu-de) in the prod target environment and the inventory branch.

To specify the deployment region by the continuous deployment pipeline, use the region parameter. For more information about this parameter, see [Continuous deployment Pipeline parameters](https://cloud.ibm.com/docs/devsecops?topic=devsecops-cd-devsecops-pipeline-parmcd-parameters).
tags = ["dev:test"]
}
primary_network_interface {
subnet = ibm_is_subnet.example.id
}
vpc = 4d27c489-8ad7-3c18-cbf4-2103d9f8da93
zone = "us-south-1"
keys = [ibm_is_ssh_key.example.id]
}

For more information about the arguments and attributes, see [ibm_is_instance](https://registry.terraform.io/providers/IBM-Cloud/ibm/latest/docs/resources/is_instance).





 Creating and attach a data volume to an instance with Terraform 

To restore a data volume from a nonbootable snapshot and attach the volume to an instance, use the ibm_is_instance_volume_attachment resource. See the following example.

resource "ibm_is_instance_volume_attachment" "example" {
instance = ibm_is_instance.example.id

name = "test-attachment-1"
profile = "general-purpose"
snapshot = "ibm_is_snapshot.example.id"
delete_volume_on_attachment_delete = true
delete_volume_on_instance_delete = true
volume_name = "restore-data-vol1"
}
}

For more information about the arguments and attributes, see [ibm_is_instance_volume_attachment](https://registry.terraform.io/providers/IBM-Cloud/ibm/latest/docs/resources/is_instance_volume_attachmentexample-usage-restoring-using-snapshot).





 Creating a stand-alone data volume from a snapshot with Terraform 

To create a volume from a snapshot, use the ibm_is_volume resource. The following example creates a volume from the snapshot bdcdc984-ba4e-4aef-84fb-e8448c3116b1 with the general-purpose performance profile.

resource "ibm_is_volume" "storage" {
name = "restore-data-vol1"
If the group members need more access later on, you simply define a new policy for the access group.
* Use access management tags to control access to the resources in your account at scale. By assigning access only to resources that have specific tags that are attached to them, you can avoid multiple updates to your defined policies. For more information, see [Controlling access to resources by using tags](https://cloud.ibm.com/docs/account?topic=account-access-tags-tutorial).
* Use trusted profiles to automatically grant federated users and compute resources access to your account. This way, federated users can be mapped to one or more trusted profiles during login by evaluating SAML-based attributes to determine which profiles they can apply. Using trusted profiles for compute resources helps you avoid storing credentials to run applications and the management and rotation of credentials. You can also add trusted profiles to access groups to leverage the set of policies you have already created.
* Regularly audit who can manage access control and delete key resources. Because the errors and misuse by users with elevated permissions can cause damage to your account, your service instances, and data protected by keys in your service instance, ensure that proper access is being maintained by auditing the users with those roles. Remember that any new keys, key rings, or service instances created are subject to existing role definitions by default. If a new key should not be accessed or modified by a new user being assigned as a Manager of the instance, that restriction must be specifically assigned, as instance managers have access to all of the keys in an instance by default, including the ability to delete a key.







 What makes a good access group strategy? 

An access group is an organization of users, service IDs, and trusted profiles in a grouping that you can grant the same IAM access. All identities in a single access group inherit the same access.

A logical way to assign access to your resource groups and the included resources is by [creating one access group](https://cloud.ibm.com/docs/account?topic=account-groups) per required level of access. Then, you can map each access group to the previously created resource groups. For example, to control access to the CustApp project, you might create the following access groups:
Why do I get a manifest version error? 

When you try to tag your image in IBM Cloud® Container Registry, you get a manifest version error: The manifest version for this image is not supported for tagging.

  What’s happening 

You tried to tag your image, but you receive the following error message: The manifest version for this image is not supported for tagging. To upgrade to a supported manifest version, pull and push this image by using Docker version 17.07 or later, then run the 'ibmcloud cr image-tag' command again.

  Why it’s happening 

The manifest version is not supported.

  How to fix it 

To resolve the problem, complete the following steps:



1.  Upgrade to a supported version of Docker, see [Support for Docker](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_overviewdocker).
2.  Pull the image that you tried to tag by running the following command, where <source_image> is your source image name:

docker pull <source_image>
3.  To upgrade the manifest version, push the image by running the following command:

docker push <source_image>
4.  Tag the image by running the ibmcloud cr image-tag command, see [Creating new images that refer to a source image](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_images_registry_images_source).
Get the logs for your sgx-installer pod to verify that you see the messages SGX driver installed and PSW installed.

oc logs <name_of_SGX_installer_pod>
6. Now that the drivers and platform software are installed, remove the daemon set.

oc delete daemonset sgx-installer
7. Delete the security context and service account that you created.

oc delete scc sgx-admin
oc delete serviceaccount sgx-admin



Now, you can develop your confidential computing app to use the enclave for sensitive data.

To uninstall the drivers and platform software, you can follow the same steps, but with the following installation command: oc create -f https://raw.githubusercontent.com/ibm-cloud-security/data-shield-reference-apps/master/scripts/sgx-driver-psw/uninstall_sgx/deployment_uninstall_sgx_openshift.yaml







 Adding tags to existing clusters 

You can assign a tag to Red Hat OpenShift on IBM Cloud clusters to help manage your IBM Cloud resources. For example, you might add key:value tags to your cluster and other cloud resources so that your billing department track resources, such as costctr:1234. Tags are visible account-wide. For more information, see [Working with tags](https://cloud.ibm.com/docs/account?topic=account-tag).

Tags are not the same thing as Kubernetes labels.
"crn": "crn:v1:bluemix:public:cf:au-syd:a/000af2ea12345aabb1234567801fffab::cf-organization:aaaf4100-0011-2233-1111-11aaffee0011"
}
],
"limit": 1,
"search_cursor": "e34535305339jg0rntt39nt3nu5tt9yn3u5ntt329nutt92u4ntt92u4t9u5gt2u5gt92u4n5g982458hg2t45hg9u42rg9t2u49gh285ght28h5t2835th85ht318h4tg9138h4tg91u3hgt931hg45918h34tg18h43hgt31hgt3rng0fnefvodnfvpojdpbojarfdbpojeafrbeafbjeqpnrqngrpqgrhbHNlIiwiY2FuVGFnIjoiZmFsc2UiLCJsdfshfksdhfkshfdkshfdkhkhewrkfehrkhkwhfkwrhkfhrgk3h5k3h45k3hk45hgk3hgk3hfk3h4k3hfkrfh3rkgh3krghk3rgh3kghk3hgk3hgk3rhgdWJsaWM6Y2Y6YXUtwriretoeiroteito4i5ot4i5oyti45ito4tio45ito45io5ogno5iogn5oin5oingoi5o5ngogo4ngo4ngro3jrong3gor3g3gno3jrgo3jrngo3ngro3g32ODQiXX0t"
}
Show more
3. Call the following command:



* Curl
* Java
* Python
* Go
* Node



curl -X POST -H "Authorization: {iam_token}" -H "Accept: application/json" -H "Content-Type: application/json" -d '{ "resources": [{ "resource_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/59bcbfa6ea2f006b4ed7094c1a08dcdd:1a0ec336-f391-4091-a6fb-5e084a4c56f4::" }], "tag_names": ["project:myproject"] }' "https://tags.global-search-tagging.cloud.ibm.com/v3/tags/attach?tag_type=access"

Resource resourceModel = new Resource.Builder().resourceId(resourceCRN).build();
AttachTagOptions attachTagOptions = new AttachTagOptions.Builder()
.addResources(resourceModel)
.addTagNames("project:myproject")
.tagType("access")
.build();

Response<TagResults> response = service.attachTag(attachTagOptions).execute();
TagResults tagResults = response.getResult();
System.out.println(tagResults.toString());

resource_model = {'resource_id': resource_crn}
You can attach access management tags to IAM-enabled resources only.

For more information about the required access for other resources types, see [Tagging permissions](https://cloud.ibm.com/docs/account?topic=account-accesstagging-permissions).





 Where can I find my resources in the IBM Cloud console? 

To view all of your resources, select from the following options:



* Click the Navigation menu icon ![Navigation Menu icon](https://cloud.ibm.com/docs-content/v1/content/4d8c6eec891cff72b666dc24bd3211810c77fb42/icons/icon_hamburger.svg) > Resource List.
* Click the Navigation menu icon ![Navigation Menu icon](https://cloud.ibm.com/docs-content/v1/content/4d8c6eec891cff72b666dc24bd3211810c77fb42/icons/icon_hamburger.svg) > Dashboard, and click any of the links that are listed in the Resource summary widget.



To view just your classic infrastructure resources, select from the following options:



* Click the Navigation menu icon ![Navigation Menu icon](https://cloud.ibm.com/docs-content/v1/content/4d8c6eec891cff72b666dc24bd3211810c77fb42/icons/icon_hamburger.svg) > Classic Infrastructure.
* Click the Navigation menu icon ![Navigation Menu icon](https://cloud.ibm.com/docs-content/v1/content/4d8c6eec891cff72b666dc24bd3211810c77fb42/icons/icon_hamburger.svg) > Dashboard, and click any of the links that are listed in the Classic infrastructure widget.







 What causes resource restorations to fail? 

A resource restoration can fail if you try to restore a resource in a deleted resource group or the resource restoration request isn't submitted in time.
[Navigation Menu icon](https://cloud.ibm.com/docs-content/v1/content/4d8c6eec891cff72b666dc24bd3211810c77fb42/icons/icon_hamburger.svg) > Resource List.
2. Locate the service in the table, and see the Tags column.



To help you quickly identify which tags are access management tags, the name is preceded by IAM in the label, for example, IAM | devtools:project1.

To check the context-based restrictions on a resource, complete the following steps:



1. In the IBM Cloud console, click Manage > Context-based restrictions, and select Rules.
2. Click the Actions icon ![Actions icon](https://cloud.ibm.com/docs-content/v1/content/4d8c6eec891cff72b666dc24bd3211810c77fb42/icons/action-menu-icon.svg) on the rule for your service.
3. Click Details.
4. Take note of the contexts for the rule. Access is granted by a rule only when at least one of the rule's contexts are satisfied by the user.
"value" : "name of the SysDig stage service instance",
"type" : "string"
} ],
"output" : {
"name" : "resource_group_id"
}, {
"name" : "logdna_id"
}, {
"name" : "sysdig_id"
} ] ! ! !
},
"project_id" : "db268db0-160b-4911-8f93-89659000a927",
"is_draft" : true,
"version" : 2,
"state" : "ACTIVE",
"pipeline_state" : "PIPELINE_SUCCEEDED",
"update_available" : true,
"created_at" : "2023-02-22T19:51:23.253Z",
"updated_at" : "2023-02-22T19:51:23.253Z"
}
<-- </section "id="section-project-config-draft-get-cli-output" "> --><-- </section "id="section-project-cli-config-draft-get-command" "> --><-- <section "id="section-project-relevant-commands-other" "> --> Other relevant commands for IBM Cloud projects The following commands are not a part of the projects CLI plug-in, but you can use them to complete project-related tasks, such as attaching tags to a project. This list is not exhaustive of all of the relevant commands that are available to use with projects. Rather, this list is a starting point for you to explore other commands that you can use with projects.Some of the following commands might require the installation of their specific plug-ins before you can run them.Run ibmcloud resource tag-attach]ibmcloud resource tag-attach] to attach tags to a project: ibmcloud resource tag-attach --tag-names TAG --resource-id PROJECT-CRN
Change log for version 2.1.4, released 1 September 2021 



* Image tags: 1.8.33
* Fixes a timeoutSeconds issue in the livenessProbe and readinessProbe.
* Updates the Golang version to v1.17.
* Updates the UBI image to 8.4-208.
* Migrates the image from the ibmcom public registry to the icr.io/cpopen registry.
* Resolves [CVE-2021-36221](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-36221), [CVE-2021-29923](https://nvd.nist.gov/vuln/detail/CVE-2021-29923), and [CVE-2021-33196](https://nvd.nist.gov/vuln/detail/CVE-2021-33196).







 Change log for version 2.1.3, released 25 August 2021 



* Image tags: 1.8.32
"crn": "crn:v1:bluemix:public:cf:au-syd:a/000af2ea12345aabb1234567801fffab::cf-organization:aaaf4100-0011-2233-1111-11aaffee0011"
}
],
"limit": 1,
"search_cursor": "e34535305339jg0rntt39nt3nu5tt9yn3u5ntt329nutt92u4ntt92u4t9u5gt2u5gt92u4n5g982458hg2t45hg9u42rg9t2u49gh285ght28h5t2835th85ht318h4tg9138h4tg91u3hgt931hg45918h34tg18h43hgt31hgt3rng0fnefvodnfvpojdpbojarfdbpojeafrbeafbjeqpnrqngrpqgrhbHNlIiwiY2FuVGFnIjoiZmFsc2UiLCJsdfshfksdhfkshfdkshfdkhkhewrkfehrkhkwhfkwrhkfhrgk3h5k3h45k3hk45hgk3hgk3hfk3h4k3hfkrfh3rkgh3krghk3rgh3kghk3hgk3hgk3rhgdWJsaWM6Y2Y6YXUtwriretoeiroteito4i5ot4i5oyti45ito4tio45ito45io5ogno5iogn5oin5oingoi5o5ngogo4ngo4ngro3jrong3gor3g3gno3jrgo3jrngo3ngro3g32ODQiXX0t"
}
3. Call the following command:



* Curl
* Java
* Python
* Go
* Node



curl -X POST -H "Authorization: {iam_token}" -H "Accept: application/json" -H "Content-Type: application/json" -d '{ "resources": [{ "resource_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/59bcbfa6ea2f006b4ed7094c1a08dcdd:1a0ec336-f391-4091-a6fb-5e084a4c56f4::" }], "tag_names": ["project:myproject"] }' "https://tags.global-search-tagging.cloud.ibm.com/v3/tags/attach?tag_type=access"

Resource resourceModel = new Resource.Builder().resourceId(resourceCRN).build();
AttachTagOptions attachTagOptions = new AttachTagOptions.Builder()
.addResources(resourceModel)
.addTagNames("project:myproject")
.tagType("access")
.build();

Response<TagResults> response = service.attachTag(attachTagOptions).execute();
TagResults tagResults = response.getResult();
System.out.println(tagResults.toString());

resource_model = {'resource_id': resource_crn}
Make a PATCH /backup_policies/{backup_policy_id}/plans/{plan_id} request to update the backup plan by specifying the following properties:



* attach_user_tags specifies the user tags from the backup policy that are to be attached to backups created by the plan. Updating this value doesn't change the user tags for backups that were already created by this plan.
* copy_user_tags specifies whether source volume tags are to be copied to the backup snapshot. The value is a Boolean, it's either true or false.
* deletion_trigger has two properties. The delete_after property sets the number of days to keep a backup. The delete_over_count property sets the maximum number of recent backups to keep. When the maximum number is reached, the oldest backup is deleted to make space for a new one. Specify null to remove the existing maximum.



curl -X PATCH "$vpc_api_endpoint/v1/backup_policies/5063bfe5-c16f-4606-ba26-fba0f099b97d/plans/78bb42ae-b82e-4560-861b-5bc4bca3fba6?version=2022-06-28&generation=2" -H "Authorization: $iam_token" -d '{
"active": true,
"attach_user_tags": [
"my-daily-backup-plan"
],
"copy_user_tags": true,
"cron_spec": "/5 1,2,3 * * ",
"deletion_trigger": {
"delete_after": 20,
"delete_over_count": 1
},
"name": "my-policy-plan"
}'
Show more





 Updating a backup policy plan for the fast restore option with the API 

Make a POST /backup_policies/{backup_policy_id}/plans/{plan_id} request to update a backup plan.
cf-ray: 69903d250c4966ef-DFW
cache-control: max-age=0, no-cache, no-store, must-revalidate
expires: -1
strict-transport-security: max-age=31536000; includeSubDomains
cf-cache-status: DYNAMIC
expect-ct: max-age=604800, report-uri="[uri...]"
pragma: no-cache
x-content-type-options: nosniff
x-request-id: 1fbe2384-6828-4503-ae7d-050426d1b11b
x-xss-protection: 1; mode=block
server: cloudflare
etag: W/xxxyyyzzz123
2. Make a PATCH /shares/{share_id} request. Specify the ETag hash string for the If-Match property in the header. Specify the user tags in the user_tags property.

This example updates the file share user tags to env:test and env:prod. The hash string value that you obtained from the ETag property (W/xxxyyyzzz123) is specified in the If-Match header in the call.

curl -X PATCH "$vpc_api_endpoint/v1/shares/50fda9c3-eecd-4152-b473-a98018ccfb10?version=2023-07-11&generation=2&maturity=beta&maturity=beta" -H "Authorization: Bearer" -H "If-Match: W/xxxyyyzzz123" -d {
"user_tags": [
"env:test2",
"env:prod2"
]
}'











 Add access management tags to a file share 

Access management tags are metadata that you can add to your file shares to help organize access control resource relationships. You first create the tag and then add it to an existing file share or when you create a file share.
Make a PATCH /backup_policies/{backup_policy_id}/plans/{plan_id} request to update the backup plan by specifying the following properties:



* attach_user_tags specifies the user tags from the backup policy that are to be attached to backups created by the plan. Updating this value doesn't change the user tags for backups that were already created by this plan.
* copy_user_tags specifies whether source volume tags are to be copied to the backup snapshot. The value is a Boolean, it's either true or false.
* deletion_trigger has two properties. The delete_after property sets the number of days to keep a backup. The delete_over_count property sets the maximum number of recent backups to keep. When the maximum number is reached, the oldest backup is deleted to make space for a new one. Specify null to remove the existing maximum.



curl -X PATCH "$vpc_api_endpoint/v1/backup_policies/5063bfe5-c16f-4606-ba26-fba0f099b97d/plans/78bb42ae-b82e-4560-861b-5bc4bca3fba6?version=2022-06-28&generation=2" -H "Authorization: $iam_token" -d '{
"active": true,
"attach_user_tags": [
"my-daily-backup-plan"
],
"copy_user_tags": true,
"cron_spec": "/5 1,2,3 * * ",
"deletion_trigger": {
"delete_after": 20,
"delete_over_count": 1
},
"name": "my-policy-plan"
}'





 Updating a backup policy plan for the fast restore option with the API 

Make a POST /backup_policies/{backup_policy_id}/plans/{plan_id} request to update a backup plan.
curl -X DELETE -H "Authorization: {iam_token}" -H "Accept: application/json" "https://tags.global-search-tagging.cloud.ibm.com//v3/tags?tag_type=access"

DeleteTagAllOptions deleteTagAllOptions = new DeleteTagAllOptions.Builder()
.tagType("user")
.build();

Response<DeleteTagsResult> response = service.deleteTagAll(deleteTagAllOptions).execute();
DeleteTagsResult deleteTagsResult = response.getResult();

System.out.println(deleteTagsResult.toString());

delete_tags_result = global_tagging_service.delete_tag_all(
tag_type='user').get_result()

print(json.dumps(delete_tags_result, indent=2))

deleteTagAllOptions := globalTaggingService.NewDeleteTagAllOptions()
deleteTagAllOptions.SetTagType("user")

deleteTagsResult, response, err := globalTaggingService.DeleteTagAll(deleteTagAllOptions)
if err != nil {
panic(err)
}
b, _ := json.MarshalIndent(deleteTagsResult, "", " ")
fmt.Println(string(b))

const params = {
tagType: 'access',
};

globalTaggingService.deleteTagAll(params)
.then(res => {
console.log(JSON.stringify(res.result, null, 2));
})
.catch(err => {
console.warn(err)
});







 Deleting tags by using Terraform 

Before you can delete tags by using Terraform, make sure that you have completed the following:
From your browser, open the [IBM Cloud console](https://cloud.ibm.com/login).
2. Select the navigation menu icon ![navigation menu](https://cloud.ibm.com/docs-content/v1/content/f02b9c9adcbb7328d95a45e105cec371d50f15eb/icons/icon_hamburger.svg), then click VPC Infrastructure.
3. Click Subnets.
4. Click Create + on the Subnets for VPC list table.
5. In the Location section, provide the following information:



* Geography: Indicate the general area where you want the subnet created.
* Region: Indicate the region where you want the subnet created.
* Zone: Indicate the zone where you want the subnet created.



6. In the Details section, provide the following information:



* Name: Enter a unique identifier for the subnet, such as my-subnet.
* Resource group: Select a resource group for the subnet.
* Tags: Optionally, add any relevant tags to help group your subnets.
* Access management tags: Optionally, add access management tags to resources to help organize access control relationships. The only supported format for access management tags is key:value. For more information, see [Controlling access to resources by using tags](https://cloud.ibm.com/docs/account?topic=account-access-tags-tutorial).
* Virtual private cloud: Select the VPC in which you want the subnet created.
* IP range selection: The most efficient location for your IP range is calculated automatically. If you want to customize the IP range instead of accepting the default selection, select a different address prefix, change the number of addresses, or enter your IP range manually.
* Routing table: Select which routing table you want the new subnet to use.
* Subnet access control list: Select which access control list you want the new subnet to use.
* Public gateway: Indicate whether you want the subnet to communicate with the public internet by toggling the switch to Attached.