vania-janet/multiturn-rag-retrieval-data huggingface dataset:
Cloud-init version 0.7.9 or greater is required.



1. To determine whether cloud-init is installed, run the following command: cloud-init --version



* In some cases, cloud-init might be installed but not in your environment PATH.
* To find the path for cloud-init on ExecStart, run the following command:systemctl cat cloud-init



2. To install cloud-init, use one of the following commands.



* For Ubuntu or Debian, run the following command: apt-get install cloud-init
* For CentOS or Red Hat, run the following command: yum install cloud-init



3. If the datasources_list property exists in /etc/cloud/cloud.cfg, verify that it only contains NoCloud or remove the datasources_list property entirely. ConfigDrive is not supported. 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 [NoCloud](https://cloudinit.readthedocs.io/en/latest/reference/datasources/nocloud.html) data source to supply the metadata.

A block device is provided. See the following example.

blkid
/dev/vdb: UUID="2023-03-15-16-50-02-00" LABEL="cidata" TYPE="iso9660"

This block device is found by cloud-init and contains the following files.



* meta-data instance-id: INSTANCE_ID local-hostname: NAME
* user-data Optional user data that was provided when the instance was created. See [User data](https://cloud.ibm.com/docs/vpc?topic=vpc-user-data) for more information.
5. (VMWare only) Enable VLAN spanning or VRF on your account
6. Set up user permissions in IAM







 Step 1. Sign up for an IBM Cloud account 

To order and use IBM Cloud services, you need to sign up for an IBM Cloud account. Billing information is associated with your IBM Cloud account and the cost of the physical and virtual infrastructure and the resulting licenses are charged to your account. For more information about signing up, see [Setting up your IBM Cloud account](https://cloud.ibm.com/docs/account?topic=account-account-getting-startedsignup).





 Step 2. Create IBM Cloud API keys 

For Classic and VMWare solutions, you need to add a classic infrastructure API key to your IBM Cloud account. For more information about creating or managing API keys, see [Managing classic infrastructure API keys](https://cloud.ibm.com/docs/account?topic=account-classic_keys).

For VPC solutions, you need to add an IBM Cloud API key to your IBM Cloud account. For more information about creating or managing API keys, see [Managing user API keys](https://cloud.ibm.com/docs/account?topic=account-userapikey&interface=ui).





 Step 3. Verify Citrix and operating system entitlements 

Verify that you have the Citrix DaaS service license available for the wanted environment size under the Licensing section of [Citrix Cloud](http://citrix.cloud.com). During the provisioning process in the IBM Cloud catalog, IBM Cloud captures your Citrix account credentials and validates with Citrix Cloud before it completes the provisioning process. You also need to verify that you have server or desktop licenses, along with any additional third-party licenses, depending on the applications that you intend to use.





 Step 4. Set up network connectivity for logging on to IBM Cloud 

All of the resources that are provisioned through this solution are in a private network space with security groups attached wherever needed. The IP addresses are internal to IBM, so you need to use a separate VPN account for logging on to hypervisors and creating the virtual machine images.
* Install the IBM Cloud CLI and the [IBM Cloud Kubernetes Service plug-in](https://cloud.ibm.com/docs/containers?topic=containers-cli-install).
* Install the [VPC CLI plug-in](https://cloud.ibm.com/docs/vpc?topic=vpc-creating-vpc-resources-with-cli-and-api&interface=cli).





1. In your command line, log in to your IBM Cloud account and target the IBM Cloud region and resource group where you want to create your VPC cluster. For supported regions, see [Creating a VPC in a different region](https://cloud.ibm.com/docs/vpc?topic=vpc-creating-a-vpc-in-a-different-region). Enter your IBM Cloud credentials when prompted. If you have a federated ID, use the --sso option to log in.

ibmcloud login -r <region> [-g <resource_group>] [--sso]
2. [Create a VPC](https://cloud.ibm.com/docs/vpc?topic=vpc-creating-vpc-resources-with-cli-and-api&interface=clicreate-a-vpc-cli) in the same region where you want to create the cluster. Do the clusters of worker nodes in your VPC need to send and receive information to and from IBM Cloud classic infrastructure? Follow the steps in [Creating VPC subnets for classic access](https://cloud.ibm.com/docs/containers?topic=containers-vpc-subnetsca_subnet_cli) to create a classic-enabled VPC and VPC subnets without the automatic default address prefixes.
3. [Create a subnet for your VPC](https://cloud.ibm.com/docs/vpc?topic=vpc-creating-vpc-resources-with-cli-and-api&interface=clicreate-a-subnet-cli).
Migrating from a Lite plan to a Standard plan 

Migrating from the free Lite plan to the Standard plan by completing the following tasks.



  Step 1: Authenticate with IBM Cloud Dashboard 



1.  Go to the [IBM Cloud® Dashboard](https://cloud.ibm.com/).
2.  Authenticate with your username and password. The IBM Cloud Dashboard opens to the Resource list.







  Step 2: Select your IBM Cloudant instance 



1.  Under Services, open the IBM Cloudant instance that you want to migrate.
2.  Select Plan.
3.  From the list of pricing plans, select Standard.

Zoom

![Standard plan is a serverless scaling of throughput and storage. Includes 20 GB of free data storage, more storage metered. Users can adjust provisioned throughput capacity in blocks of 100 reads/sec, 50 writes/sec, 5 global queries/sec. Max JSON document size of 1 MB. $1.00 USD/GB of data storage. $0.25 USD/Read capacity. $0.50 USD/Write capacity. $5.00 USD/Global Query capacity.](https://cloud.ibm.com/docs-content/v1/content/522c6f62358b063f921283400a601c3f9bc66f08/Cloudant/images/migrate3.png)

Figure 1. Standard plan







  Step 3: Upgrade to the Standard plan 



1.  Click Upgrade. All your existing data is kept.
2.  Adjust your capacity by using the Throughput Capacity slider to increase or decrease capacity as needed.



Now, you're ready to go.
For more information, see [General CLI (ibmcloud) commands](https://cloud.ibm.com/docs/cli?topic=cli-ibmcloud_cliibmcloud_target) under ibmcloud target.

ibmcloud target [-r REGION_NAME] [-g RESOURCE_GROUP]
2. To see a list of regions, run the following command.

ibmcloud regions
3. To see a list of resource groups, run the following command.

ibmcloud resource groups
4. Create an instance of an IBM Cloudant service by using the Lite plan.
The instance name is cs20170517a in the US-South location and uses IAM credentials only.

ibmcloud resource service-instance-create cs20170517a cloudantnosqldb lite us-south -p '{"legacyCredentials": false}'
5. After you create the service instance, see the following example message.

Creating service instance cs20170517a in resource group default of account John Does's Account as j.doe@email.com...
OK
Service instance cs20170517a was created.
Name Location State Tags
cs20170517a au-syd active service_instance



Next, you create service credentials for your IBM Cloudant service instance.





 Step 3: Creating credentials for your IBM Cloudant service 

Applications that require access to your IBM Cloudant service must have the necessary credentials.

Service credentials are valuable. If anyone or any application has access to the credentials, they can effectively do whatever they want with the service instance. For example, they might create spurious data, or delete valuable information. Protect these credentials carefully.

For more information about the fields included in the service credentials, see the [IAM guide](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-managing-access-for-cloudant).

In the next example, you create credentials for a service instance within IBM Cloud by running the following command.
You can start with an IBM Cloud Terraform Provider example, such as [ibm-cd-toolchain-simple-helm](https://github.com/IBM-Cloud/terraform-provider-ibm/tree/master/examples/ibm-cd-toolchain-simple-helm) or [ibm-cd-tekton-pipeline](https://github.com/IBM-Cloud/terraform-provider-ibm/tree/master/examples/ibm-cd-tekton-pipeline), or you can write your own Terraform.

To start working with Terraform, see [Setting up Terraform for Continuous Delivery](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-terraform-setup). For more information about the Terraform resources and data sources for IBM Cloud including the Continuous Delivery service, see the [IBM Cloud Provider Documentation](https://registry.terraform.io/providers/IBM-Cloud/ibm/latest/docs).
Getting started with High Availability and Resiliency for IBM Cloud 

Use Citrix DaaS for IBM Cloud® to create a dedicated Citrix DaaS service environment at any of our global data centers. You have the option of creating a Classic solution, VMWare solution, or VPC solution.



  Before you begin 

After you review this information, you are ready to get started. To begin, you need to complete the following prerequisites.



1.  Sign up for an IBM Cloud account
2.  Create required API keys
3.  Create required SSH keys







  Step 1. Sign up for an IBM Cloud account 

To deploy highly available and resilient resources, you need to sign up for an IBM Cloud account. Billing information is associated with your IBM Cloud account and the cost of the physical and virtual infrastructure and the resulting licenses are charged to your account. For more information about signing up, see [Setting up your IBM Cloud account](https://cloud.ibm.com/docs/account?topic=account-account-getting-startedsignup).





  Step 2. Create IBM Cloud API keys 

For Classic deployments, you need to add a classic infrastructure API key to your IBM Cloud account. For more information about creating or managing API keys, see [Managing classic infrastructure API keys](https://cloud.ibm.com/docs/account?topic=account-classic_keys).

For VPC solutions, you need to add an IBM Cloud API key to your IBM Cloud account. For more information about creating or managing API keys, see [Managing user API keys](https://cloud.ibm.com/docs/account?topic=account-userapikey&interface=ui).





  Step 3. Create IBM Cloud SSH keys 

Create or retrieve your [SSH key name](https://cloud.ibm.com/docs/ssh-keys?topic=ssh-keys-getting-started-tutorial). The SSH key is used to SSH to the bastion server.





  Next steps 

To continue, see [High Availability and Resiliency on IBM Cloud](https://cloud.ibm.com/docs/ha-infrastructure?topic=landing-about-ha-dr-backup).
"fmt"
"github.com/IBM/cloudant-go-sdk/cloudantv1"
)

See the following example of highlighted search results:

{
"highlights": {
"movie_name": [
" on the Azazel Orient Express",
" Azazel manuals, you"
]
}
}





 Search index metadata 

To retrieve information about a search index, you send a GET request to the _search_info endpoint, as shown in the following example. DDOC refers to the design document that includes the index, and INDEX_NAME is the name of the index.

See the following example that uses HTTP to request search index metadata:

GET /$DATABASE/_design/$DDOC/_search_info/$INDEX_NAME HTTP/1.1

See the following example that uses the command line to request search index metadata:



* Curl
* Java
* Node
* Python
* Go



curl "https://$ACCOUNT.cloudant.com/$DATABASE/_design/$DDOC/_search_info/$INDEX_NAME" -X GET

import com.ibm.cloud.cloudant.v1.Cloudant;
import com.ibm.cloud.cloudant.v1.model.GetSearchInfoOptions;
import com.ibm.cloud.cloudant.v1.model.SearchInfoResult;

Cloudant service = Cloudant.newInstance();

GetSearchInfoOptions infoOptions =
new GetSearchInfoOptions.Builder()
.db("<db-name>")
.ddoc("<ddoc>")
.index("<index-name>")
.build();

SearchInfoResult response =
service.getSearchInfo(infoOptions).execute()
.getResult();

System.out.println(response);

import { CloudantV1 } from '@ibm-cloud/cloudant';

const service = CloudantV1.newInstance({});
* For Linux™, extract the package and run the install script.



3. Log in to IBM Cloud:

ibmcloud login

Now, you're ready to manage IBM Cloud resources. Enter ibmcloud help to view the command descriptions.

If you're using a federated ID, [log in with a one-time passcode or an API key](https://cloud.ibm.com/docs/account?topic=account-federated_id).







 Installing from the shell 

To install the latest CLI for your OS from the shell manually, use the following command for your OS:

If you don't want to install from the shell because it might utilize root permissions, you can [download and run the installer](https://cloud.ibm.com/docs/cli?topic=cli-install-ibmcloud-cliibmcloud-cli-installer).



* For Mac, copy and paste the following command to a terminal and run it:

curl -fsSL https://clis.cloud.ibm.com/install/osx | sh
* For Linux™, copy and paste the following command to a terminal and run it:

curl -fsSL https://clis.cloud.ibm.com/install/linux | sh
* For Windows™, copy and paste the following command to a [Windows™ PowerShell](https://msdn.microsoft.com/en-us/powershell/scripting/getting-started/getting-started-with-windows-powershell) terminal console and run it:

iex (New-Object Net.WebClient).DownloadString('https://clis.cloud.ibm.com/install/powershell')

If you encounter errors like The underlying connection was closed: An unexpected error occurred on a send, make sure you have .Net Framework 4.5 or later installed. Also try to enable TLS 1.2 protocol by running the following command:

[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12







 Installing to a custom directory
Viewing the source code of the completed application in your preferred editor might be helpful as you follow the next steps. This is the version of your webapplication that is committed and deployed to IBM Cloud Platform when you complete this tutorial.



 Designing the app 

These are the two main tasks that a user should be able to do with the simple image gallery web application:

- Upload images from a web browser to the Object Storage bucket.
- View the images in the Object Storage bucket in a web browser.

The next steps focus on how to accomplish these two demonstration functions rather than building a fully developed, production-grade app. Deploying this tutorial and leaving it exposed and running means that anyone who finds the app can perform the same actions: upload files to your IBM Cloud Object Storage bucket and view any JPEG images already there in their browser.





 Developing the app 

In the package.json file, inside the scripts object, you see how "start" is defined. This file is what IBM Cloud Platform uses to tell node to run app.js each time the app starts. Also, use it when testing the app locally. Look at the main application file, which is called app.js. This is the code that we have told Node.js to process first when you start your app with the npm start command (or nodemon).

{
"scripts": {
"start": "node app.js"
}
}

Our app.js file uses node to load modules that are needed to get started. The Express framework creates the app as a singleton simply called app. The example ends (leaving out most of the code for now) telling the app to listen on the port that is assigned and an environment property, or 3000 by default. When successfully starting at the start, it prints a message with the server URL to the console.

var express = require('express');
var cfenv = require('cfenv');
var bodyParser = require('body-parser');
var app = express();
//...

// start server on the specified port and binding host
For more information, see [Creating service credentials](https://cloud.ibm.com/docs/Cloudant?topic=Cloudant-migrating-to-iam-onlycreating-service-credentials) for further instructions.







 Step 2: Updating applications 



1. Update all applications to use IAM access tokens when you authenticate with the IBM Cloudant instance.







 Step 3: Migrating to IAM only 

This operation cannot be undone. Make sure all applications that access the instance are using IAM to authenticate before you start this step.



1. Go to [IBM Cloud](https://cloud.ibm.com/resources).
2. Find your IBM Cloudant instance on the list of resources and open it.

Zoom

![Select your instance.](https://cloud.ibm.com/docs-content/v1/content/522c6f62358b063f921283400a601c3f9bc66f08/Cloudant/tutorials/images/img0011.png)

Figure 1. Resource list
3. Click the Migrate to IAM Only button under the Authentication methods section. If you do not see the button, your instance is already IAM Only.

Zoom

![Migrate to IAM Only.](https://cloud.ibm.com/docs-content/v1/content/522c6f62358b063f921283400a601c3f9bc66f08/Cloudant/tutorials/images/authentication_methods_root_credential.png)

Figure 2. Authentication methods
4. Click OK to confirm your action on the dialog window to proceed. If the instance URL-style credential is still enabled, the confirmation box differs. You still click OK to confirm your action on the dialog window to proceed.
5. When the operation completes successfully, the Authentication methods row shows only IBM Cloud IAM.

Zoom

![Migration complete.]
You might choose to start with the [Deploy a secure app with DevSecOps best practices](https://cloud.ibm.com/docs/devsecops?topic=devsecops-tutorial-cd-devsecops) tutorial, which takes you through various common continuous integration, continuous deployment, and continuous compliance paths.

Other useful learning aids are available as follows:



* [Getting started with IBM Cloud® Continuous Delivery](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-getting-started)
* [Installing Delivery Pipeline private workers](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-install-private-workers)
* [Working with Tekton pipelines](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-tekton-pipelines)
* [Getting started with the IBM Cloud® Command Line Interface (CLI)](https://cloud.ibm.com/docs/cli?topic=cli-getting-started)
* [Continuous Deployment to Kubernetes](https://cloud.ibm.com/docs/solution-tutorials?topic=solution-tutorials-continuous-deployment-to-kubernetes)
* [Getting started with IBM Cloud® Kubernetes Service](https://cloud.ibm.com/docs/containers?topic=containers-getting-started)
* [Toolchain availability, templates, and tutorials](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-cd_about)
Make sure that you select a supported RHEL 7 or 8 operating system or a supported Red Hat CoreOS (RHCOS) image, configure the machine with at least 4 CPU and 16 RAM, and add a boot disk with a size of at least 100 GB.
2. Wait for your virtual server instance to be provisioned.
3. Get the registration script to attach hosts to your IBM Cloud Satellite location. Note that the token in the script is an API key, which should be treated and protected as sensitive information. Make a note of the location of the attach script. Also note that for RHEL-based hosts, the attach script is a Shell script.

ibmcloud sat host attach --location <location_name_or_ID>
4. Retrieve the IP address and ID of your machine.



* Classic

ibmcloud sl vs list
* VPC

ibmcloud is instances



5. Retrieve the credentials to log in to your virtual machine.



* Classic

ibmcloud sl vs credentials <vm_ID>
* VPC

ibmcloud is instance-initialization-values <instance_ID>



6. Copy the script from your local machine to the virtual server instance.

scp <path_to_attachHost.sh> root@<ip_address>:/tmp/attach.sh

If you use an SSH key to log in, make sure to convert the key to .key format and use the following command.

scp -i <filepath_to_key_file.key> <filepath_to_script> <username>@<IP_address>:/tmp/attach.sh
7. Log in to your virtual machine. If prompted, enter the password that you retrieved earlier.

ssh root@<ip_address>

If you use an SSH key to log in, use the following command.

ssh -i <filepath_to_key_file.key> <username>@<IP_address>
8. Refresh the Red Hat packages on your machine.

subscription-manager refresh
9.
ibmcloud login

If you have a federated user ID, instead use the following command to log in with your single sign-on ID. See [Logging in with a federated ID](https://cloud.ibm.com/docs/account?topic=account-federated_id) to learn more.

ibmcloud login --sso
2. Target a Cloud Foundry org and space:

ibmcloud target --cf

If you don't have an org or a space set up, see [Adding orgs and spaces](https://cloud.ibm.com/docs/account?topic=account-orgsspacesusers).
3. From within the get-started-node directory, push your app to IBM Cloud®.

ibmcloud cf push

This can take a minute. If there is an error in the deployment process you can use the command ibmcloud cf logs <Your-App-Name> --recent to troubleshoot.



When deployment completes you should see a message indicating that your app is running. View your app at the URL listed in the output of the push command. You can also issue the following command to view your apps status and see the URL.

ibmcloud cf apps

You can also go to the IBM Cloud [resource list](https://cloud.ibm.com/resources) to view your app.





 Step 5: Add a database 

Next, we'll add an IBM Cloudant NoSQL database to this app and set up the app so that it can run locally and on IBM Cloud.



1. In your browser, log in to IBM Cloud and go to the Dashboard. Select Create resource.
2. Search for IBM Cloudant, and select the service.
3. For Available authentication methods, select Use both legacy credentials and IAM. You can leave the default settings for the other fields. Click Create to create the service.
4. In the navigation, go to Connections, then click Create connection. Select your app, and click Connect.
5. Using the default values, click Connect & restage app to connect the database to your app.
For more information, see the tutorial for [Getting started with Terraform on IBM Cloud®](https://cloud.ibm.com/docs/ibm-cloud-provider-for-terraform?topic=ibm-cloud-provider-for-terraform-getting-started). The plug-in abstracts the IBM Cloud APIs that are used to complete this task.
* Create a Terraform configuration file that is named main.tf. In this file, you define resources by using HashiCorp Configuration Language. For more information, see the [Terraform documentation](https://www.terraform.io/docs/language/index.html).



Use the following steps to add users to your access groups



1. In your Terraform configuration file, find the Terraform code that you used to [create the access group](https://cloud.ibm.com/docs/account?topic=account-groups&interface=terraformcreate-ag-terraform) and note the access_group_id assigned to your access group.
2. Add a member to the access group.

resource "ibm_iam_access_group_members" "accgroupmem" {
access_group_id = ibm_iam_access_group.accgroup.id
ibm_ids = ["test@in.ibm.com"]
}

For more information, see the argument reference details on the [Terraform Identity and Access Management (IAM)](https://registry.terraform.io/providers/IBM-Cloud/ibm/latest/docs/resources/iam_access_group_members) page.
3. After you finish building your configuration file, initialize the Terraform CLI. For more information, see [Initializing Working Directories](https://www.terraform.io/cli/init).

terraform init
4. Provision the resources from the main.tf file. For more information, see [Provisioning Infrastructure with Terraform](https://www.terraform.io/cli/run).



1.