| name | oraclecloud-deploy-integration |
| description | Deploy containers to OCI using OKE (Kubernetes) or Container Instances.
Use when deploying applications to Oracle Cloud, pushing images to OCIR, or configuring OKE clusters.
Trigger with "oraclecloud deploy", "oci kubernetes", "oke deploy", "oci container instances", "oracle cloud deploy integration".
|
| allowed-tools | Read, Write, Edit, Bash(pip:*), Bash(kubectl:*), Bash(docker:*), Grep |
| version | 1.7.0 |
| license | MIT |
| author | Jeremy Longshore <jeremy@intentsolutions.io> |
| tags | ["saas","oraclecloud","oci"] |
| compatibility | Designed for Claude Code |
Oracle Cloud Deploy Integration
Overview
Deploy containerized applications to OCI using either OKE (Oracle Kubernetes Engine) or Container Instances. OKE provides full Kubernetes but requires 4x more config than EKS — you need a VCN, subnet, node pool, OCIR registry, and IAM policies before a single pod runs. Container Instances offer a simpler serverless alternative for workloads that don't need Kubernetes orchestration.
Purpose: Get containers running on OCI through both the full Kubernetes path (OKE) and the simpler Container Instances path, with working manifests and registry auth.
Prerequisites
- OCI tenancy with an API signing key in
~/.oci/config
- Python 3.8+ with
pip install oci for SDK-based provisioning
- Docker installed for building and pushing images
- kubectl installed for OKE cluster interaction
- Compartment OCID where resources will be created
- VCN with subnets — at least one public and one private subnet for OKE
Instructions
Step 1: Push Container Image to OCIR
Oracle Cloud Infrastructure Registry (OCIR) is OCI's Docker-compatible registry. Auth uses an OCI auth token, not your API key:
docker login us-ashburn-1.ocir.io
docker tag myapp:latest us-ashburn-1.ocir.io/{namespace}/myapp:latest
docker push us-ashburn-1.ocir.io/{namespace}/myapp:latest
Step 2: Create OKE Cluster via Python SDK
Use the OCI Python SDK to provision an OKE cluster programmatically:
import oci
config = oci.config.from_file("~/.oci/config")
container_engine = oci.container_engine.ContainerEngineClient(config)
create_cluster_response = container_engine.create_cluster(
oci.container_engine.models.CreateClusterDetails(
name="my-oke-cluster",
compartment_id="ocid1.compartment.oc1..example",
vcn_id=,
kubernetes_version=,
options=oci.container_engine.models.ClusterCreateOptions(
service_lb_subnet_ids=[],
kubernetes_network_config=oci.container_engine.models.KubernetesNetworkConfig(
pods_cidr=,
services_cidr=
)
)
)
)
cluster_id = create_cluster_response.headers[]
()