You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| <aname="input_access_config"></a> [access\_config](#input\_access\_config)| Access configurations, i.e. IPs via which this instance can be accessed via the Internet. Omit to ensure that the instance is not accessible from the Internet. If omitted, ssh provisioners will not work unless Terraform can send traffic to the instance's network. This can be represented as multiple maps | <pre>list(object({<br> nat_ip = optional(string, null)<br> public_ptr_domain_name = optional(string)<br> network_tier = optional(string)<br> }))</pre> |`[]`| no |
208
+
| <aname="input_access_config"></a> [access\_config](#input\_access\_config)| Access configurations, i.e. IPs via which this instance can be accessed via the Internet. Omit to ensure that the instance is not accessible from the Internet. If omitted, ssh provisioners will not work unless Terraform can send traffic to the instance's network. This can be represented as multiple maps | <pre>list(object({<br/> nat_ip = optional(string, null)<br/> public_ptr_domain_name = optional(string)<br/> network_tier = optional(string)<br/> }))</pre> |`[]`| no |
209
209
| <aname="input_allow_stopping_for_update"></a> [allow\_stopping\_for\_update](#input\_allow\_stopping\_for\_update)| If true, allows Terraform to stop the instance to update its properties |`bool`|`null`| no |
210
210
| <aname="input_automatic_restart"></a> [automatic\_restart](#input\_automatic\_restart)| Specifies if the instance should be restarted if it was terminated by Compute Engine (not a user). |`bool`|`true`| no |
211
211
| <aname="input_boot_disk_auto_delete"></a> [boot\_disk\_auto\_delete](#input\_boot\_disk\_auto\_delete)| Whether the disk will be auto-deleted when the instance is deleted. |`bool`|`true`| no |
212
212
| <aname="input_boot_disk_byo_encryption_key"></a> [boot\_disk\_byo\_encryption\_key](#input\_boot\_disk\_byo\_encryption\_key)| A 256-bit [customer-supplied encryption key] (https://cloud.google.com/compute/docs/disks/customer-supplied-encryption), encoded in RFC 4648 base64 to encrypt this disk. |`string`|`null`| no |
213
213
| <aname="input_boot_disk_labels"></a> [boot\_disk\_labels](#input\_boot\_disk\_labels)| A set of key/value label pairs assigned to the disk. This field is only applicable for persistent disks. |`map(string)`|`{}`| no |
214
214
| <aname="input_boot_disk_mode"></a> [boot\_disk\_mode](#input\_boot\_disk\_mode)| The mode in which to attach this disk, either READ\_WRITE or READ\_ONLY. |`string`|`"READ_WRITE"`| no |
215
-
| <aname="input_boot_disk_size"></a> [boot\_disk\_size](#input\_boot\_disk\_size)| Size of the OS disk |`number`|`100`| no |
215
+
| <aname="input_boot_disk_size"></a> [boot\_disk\_size](#input\_boot\_disk\_size)| Size of the OS disk |`number`|`500`| no |
216
216
| <aname="input_boot_disk_source"></a> [boot\_disk\_source](#input\_boot\_disk\_source)| The name or self\_link of the existing disk (such as those managed by google\_compute\_disk) or disk image. |`string`|`null`| no |
217
-
| <aname="input_boot_disk_type"></a> [boot\_disk\_type](#input\_boot\_disk\_type)| Disk type associated with the OS disk. Values can be either pd-ssd, local-ssd, or pd-standard |`string`|`"pd-ssd"`| no |
217
+
| <aname="input_boot_disk_type"></a> [boot\_disk\_type](#input\_boot\_disk\_type)| Disk type associated with the OS disk. Values can be either pd-ssd, local-ssd, or pd-standard |`string`|`null`| no |
218
218
| <aname="input_boot_image_family"></a> [boot\_image\_family](#input\_boot\_image\_family)| The image from which to initialize this disk |`string`|`"ubuntu-2204-lts"`| no |
219
219
| <aname="input_boot_image_project"></a> [boot\_image\_project](#input\_boot\_image\_project)| The ID of the project in which the source image resides. |`string`|`"ubuntu-os-cloud"`| no |
220
220
| <aname="input_can_ip_forward"></a> [can\_ip\_forward](#input\_can\_ip\_forward)| Conditional that allows sending and receiving of packets with non-matching source or destination IPs. |`bool`|`false`| no |
@@ -226,7 +226,7 @@ No modules.
226
226
| <aname="input_enable_secure_boot"></a> [enable\_secure\_boot](#input\_enable\_secure\_boot)| Verify the digital signature of all boot components, and halt the boot process if signature verification fails. |`bool`|`false`| no |
227
227
| <aname="input_enable_vtpm"></a> [enable\_vtpm](#input\_enable\_vtpm)| Use a virtualized trusted platform module, which is a specialized computer chip you can use to encrypt objects like keys and certificates. |`bool`|`true`| no |
228
228
| <aname="input_hostname"></a> [hostname](#input\_hostname)| A custom hostname for the instance. Must be a fully qualified DNS name and RFC-1035-valid |`string`|`null`| no |
229
-
| <aname="input_ipv6_access_config"></a> [ipv6\_access\_config](#input\_ipv6\_access\_config)| Access configurations, i.e. IPs via which this instance can be accessed via the Internet. Omit to ensure that the instance is not accessible from the Internet. If omitted, ssh provisioners will not work unless Terraform can send traffic to the instance's network. This can be represented as multiple maps | <pre>list(object({<br> public_ptr_domain_name = optional(string, null)<br> network_tier = optional(string, null)<br> }))</pre> |`[]`| no |
229
+
| <aname="input_ipv6_access_config"></a> [ipv6\_access\_config](#input\_ipv6\_access\_config)| Access configurations, i.e. IPs via which this instance can be accessed via the Internet. Omit to ensure that the instance is not accessible from the Internet. If omitted, ssh provisioners will not work unless Terraform can send traffic to the instance's network. This can be represented as multiple maps | <pre>list(object({<br/> public_ptr_domain_name = optional(string, null)<br/> network_tier = optional(string, null)<br/> }))</pre> |`[]`| no |
230
230
| <aname="input_machine_type"></a> [machine\_type](#input\_machine\_type)| The machine type to create |`string`|`"c3-standard-4"`| no |
231
231
| <aname="input_name"></a> [name](#input\_name)| A unique name for the resource, required by GCE. Changing this forces a new resource to be created. |`string`| n/a | yes |
232
232
| <aname="input_network"></a> [network](#input\_network)| The name or self\_link of the network to attach this interface to. |`string`|`"default"`| no |
@@ -236,7 +236,7 @@ No modules.
236
236
| <aname="input_preemptible"></a> [preemptible](#input\_preemptible)| Specifies if the instance is preemptible. If this field is set to true, then automatic\_restart must be set to false. |`bool`|`false`| no |
237
237
| <aname="input_project"></a> [project](#input\_project)| The ID of the project in which the resource resides. |`string`|`""`| no |
238
238
| <aname="input_provisioning_model"></a> [provisioning\_model](#input\_provisioning\_model)| Describe the type of preemptible VM. This field accepts the value STANDARD or SPOT |`string`|`"STANDARD"`| no |
239
-
| <aname="input_service_account"></a> [service\_account](#input\_service\_account)| Service account and scopes that will be associated with the GCE instance. | <pre>object({<br> service_email = optional(string, null)<br> scopes = optional(set(string), [])<br> })</pre> |`{}`| no |
239
+
| <aname="input_service_account"></a> [service\_account](#input\_service\_account)| Service account and scopes that will be associated with the GCE instance. | <pre>object({<br/> service_email = optional(string, null)<br/> scopes = optional(set(string), [])<br/> })</pre> |`{}`| no |
240
240
| <aname="input_stack_type"></a> [stack\_type](#input\_stack\_type)| he stack type for this network interface to identify whether the IPv6 feature is enabled or not. |`string`|`"IPV4_ONLY"`| no |
241
241
| <aname="input_subnetwork"></a> [subnetwork](#input\_subnetwork)| The name or self\_link of the subnetwork to attach this interface to. Either network or subnetwork must be provided. |`string`|`null`| no |
242
242
| <aname="input_subnetwork_project"></a> [subnetwork\_project](#input\_subnetwork\_project)| The project in which the subnetwork belongs. If the subnetwork is a name and this field is not provided, the provider project is used. |`string`|`null`| no |
## GCP C4 Instance with 5th Generation Intel® Xeon® Scalable Processor (Emerald Rapids) & Open Platform for Enterprise AI (OPEA) ChatQnA Example
10
+
11
+
This demo will showcase Retrieval Augmented Generation (RAG) CPU inference using 5th Gen Xeon Scalable Processors on GCP using the OPEA ChatQnA Example. For more information about OPEA, go [here](https://opea.dev/). For more information on this specific example, go [here](https://github.com/opea-project/GenAIExamples/tree/main/ChatQnA).
12
+
13
+
## Usage
14
+
15
+
## After cloning the repo, modify /examples/gen-ai-xeon-opea-chatqna/variables.tf to add your Huggingface Token
16
+
17
+
Some Models required a Token. Modify the Huggingface Token variable to your specific Huggingface Token, for information on creating a Huggingface token go [here](https://huggingface.co/docs/hub/en/security-tokens)
18
+
19
+
```hcl
20
+
variable "huggingface_token" {
21
+
description = "Huggingface Token"
22
+
default = " <YOUR HUGGINGFACE TOKEN> "
23
+
type = string
24
+
}
25
+
```
26
+
27
+
**If needed, also modify values on /examples/gen-ai-xeon-opea-chatqna/main.tf to match your needs**
28
+
29
+
## GCP Cloud Shell Usage
30
+
31
+
1. Log on to GCP Portal
32
+
2. Enter the GCP Cloud Shell (terminal button on top right of page)
cd terraform-intel-gcp-vm/examples/gen-ai-xeon-opea-chatqna
39
+
# ADD TOKEN TO variables.tf (SEE ABOVE)
40
+
terraform init
41
+
terraform plan
42
+
terraform apply
43
+
44
+
# (enter your GCP project ID and "yes" to confirm)
45
+
46
+
```
47
+
48
+
After the Terraform module successfully creates the GCP VM instance, **wait ~15 minutes** for the module to launch the containers and download the LLMs before continuing.
49
+
50
+
## Accessing the Demo
51
+
52
+
You can access the demos using the following:
53
+
54
+
- OPEA ChatQnA: `http://yourpublicip:5174`
55
+
56
+
57
+
## Deleting the Demo
58
+
59
+
To delete the demo, run `terraform destroy` to delete all resources created.
60
+
61
+
## Pre-requisites for running on a local Workstation (disregard if using GCP Cloud Shell)
62
+
63
+
1. Google Cloud CLI: https://cloud.google.com/sdk/docs/install
Copy file name to clipboardExpand all lines: main.tf
+3-1
Original file line number
Diff line number
Diff line change
@@ -7,12 +7,14 @@
7
7
# Intel CPU, we are not populating the min CPU platform. We are using the default CPU platform that GCP will provide for these older generation of instances
0 commit comments