{"id":44863683,"url":"https://github.com/oracle-terraform-modules/terraform-oci-compute-instance","last_synced_at":"2026-02-17T10:46:09.561Z","repository":{"id":38272581,"uuid":"154190268","full_name":"oracle-terraform-modules/terraform-oci-compute-instance","owner":"oracle-terraform-modules","description":"Terraform Module for creating Oracle Cloud Infrastructure compute instances","archived":false,"fork":false,"pushed_at":"2024-07-23T08:28:24.000Z","size":114,"stargazers_count":51,"open_issues_count":38,"forks_count":74,"subscribers_count":10,"default_branch":"main","last_synced_at":"2026-02-15T03:44:16.539Z","etag":null,"topics":["automation","cloud","iac","instances","oci","oracle","oracle-cloud-infrastructure","terraform","terraform-module"],"latest_commit_sha":null,"homepage":"https://registry.terraform.io/modules/oracle-terraform-modules/compute-instance/oci/latest","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oracle-terraform-modules.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.adoc","contributing":"CONTRIBUTING.adoc","funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-10-22T17:55:26.000Z","updated_at":"2026-02-14T09:38:25.000Z","dependencies_parsed_at":"2023-02-14T11:02:00.976Z","dependency_job_id":null,"html_url":"https://github.com/oracle-terraform-modules/terraform-oci-compute-instance","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"purl":"pkg:github/oracle-terraform-modules/terraform-oci-compute-instance","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oracle-terraform-modules%2Fterraform-oci-compute-instance","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oracle-terraform-modules%2Fterraform-oci-compute-instance/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oracle-terraform-modules%2Fterraform-oci-compute-instance/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oracle-terraform-modules%2Fterraform-oci-compute-instance/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oracle-terraform-modules","download_url":"https://codeload.github.com/oracle-terraform-modules/terraform-oci-compute-instance/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oracle-terraform-modules%2Fterraform-oci-compute-instance/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29540387,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-17T08:11:05.436Z","status":"ssl_error","status_checked_at":"2026-02-17T08:09:38.860Z","response_time":100,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","cloud","iac","instances","oci","oracle","oracle-cloud-infrastructure","terraform","terraform-module"],"created_at":"2026-02-17T10:46:07.381Z","updated_at":"2026-02-17T10:46:09.173Z","avatar_url":"https://github.com/oracle-terraform-modules.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Oracle Cloud Infrastructure Terraform Module for Compute Instance\n\nThis module provides an easy way to launch compute instances with advanced settings and good practices embedded.\n\nOn top of the compute instance capabilities, this module can also:\n\n- provision and attach additional Block Volumes to the instances,\n- assign a reserved public IP, instead of using Ephemeral,\n- assign a backup policy for boot volumes\n\n**Please Note:**\n\n\u003e All Oracle-provided images include firewall rules that allow only \"root\" on Linux instances or \"Administrators\" on Windows Server instances to make outgoing connections to the iSCSI network endpoints (169.254.0.2:3260, 169.254.2.0/24:3260) that serve the instance's boot and block volumes.\n\u003e\n\u003e Oracle recommends that you do not use custom images without these rules unless you understand the security risks. See [Compute Best Practices](https://docs.cloud.oracle.com/iaas/Content/Compute/References/bestpracticescompute.htm#two) for recommendations on how to manage instances.\n\n## Requirements\n\nThe diagram below summarizes the required components and their respective versions to use this module.\n\n![versions](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/blob/main/docs/diagrams/versions.svg?raw=true\u0026sanitize=true)\n\nTo enforce versions compatibility of both Terraform and the OCI provider, your root configuration should ideally include this block for version pinning:\n\n```HCL\nterraform {\n  required_version = \"\u003e= 0.12.6\"\n  required_providers {\n    oci = {\n      version = \"\u003e= 4.0.0\"\n    }\n  }\n}\n```\n\nFor detailed information about inputs and outputs, and potential sub-modules, see [docs/terraformoptions](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/blob/main/docs/terraformoptions.adoc).\n\n## How to use this module\n\n*See [Oracle Cloud Infrastructure documentation](https://docs.oracle.com/en-us/iaas/Content/API/SDKDocs/terraformproviderconfiguration.htm) to get started with the Oracle Cloud Infrastructure Terraform Provider.*\n\nThe [examples](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/tree/main/examples/) folder contains detailed examples that shows how to use this module. The following code example creates an Oracle Cloud Infrastructure compute instance on AD-1 with an additional Block Volume attached:\n\n```hcl\nmodule \"instance\" {\n  source = \"oracle-terraform-modules/compute-instance/oci\"\n  instance_count             = 1 # how many instances do you want?\n  ad_number                  = 1 # AD number to provision instances. If null, instances are provisionned in a rolling manner starting with AD1\n  compartment_ocid           = var.compartment_ocid\n  instance_display_name      = var.instance_display_name\n  source_ocid                = var.source_ocid\n  subnet_ocids               = var.subnet_ocids\n  public_ip                  = var.public_ip # NONE, RESERVED or EPHEMERAL\n  ssh_public_keys            = var.ssh_public_keys\n  block_storage_sizes_in_gbs = [50]\n  shape                      = var.shape\n  instance_state             = var.instance_state # RUNNING or STOPPED\n  boot_volume_backup_policy  = var.boot_volume_backup_policy # disabled, gold, silver or bronze\n}\n```\n\n## What's coming next for this module?\n\nThe current focus is to close the gap between this module and the provider's capabilities. We started with a complete codebase update for [HCL2 syntax compatibility](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/releases/tag/v2.0.2), then adding support for [Regional Subnets](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/releases/tag/v2.0.4) and lastly [Flexible Shapes](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/pull/49).\n\nWe will continue to push in that direction with the goal of [feature parity with the provider's capabilities](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/projects/4), as well as adding more features and integration points with other OCI services: Block Volume Backups, Secondary VNICs and IPs, etc ...\n\nGiven the dependency to Network and Storage for Compute Instances, this module is also a perfect place to illustrate [module composition principles](https://www.terraform.io/docs/language/modules/develop/composition.html) and how to reuse the other official Terraform OCI modules.\n\n## Contributing\n\nThis project is open source and maintained by Oracle.  \nOracle appreciates any contributions that are made by the open source community: raising issues, improving documentation, fixing bugs, or adding new features.\n\nLearn how to [contribute](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/blob/main/CONTRIBUTING.adoc).\n\n[Folks who contributed](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/blob/main/CONTRIBUTORS.adoc) with explanations, code, feedback, ideas, testing etc.\n\n## License\n\nCopyright (c) 2021, Oracle and/or its affiliates. All rights reserved.\n\nLicensed under the Universal Permissive License 1.0 or Apache License 2.0.\n\nSee [LICENSE](https://github.com/oracle-terraform-modules/terraform-oci-compute-instance/blob/main/LICENSE.txt) for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foracle-terraform-modules%2Fterraform-oci-compute-instance","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foracle-terraform-modules%2Fterraform-oci-compute-instance","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foracle-terraform-modules%2Fterraform-oci-compute-instance/lists"}