Skip to main content

O8 Integration with Cloud Infrastructure Management (CIM)

Overview

Orchestr8's secrets management is designed to be the foundation for a complete Cloud Infrastructure Management solution that handles the entire lifecycle of cloud resources, secrets, and deployments.

CIM Architecture with O8

┌─────────────────────────────────────────────────────────────────┐
│ Cloud Infrastructure Management │
├─────────────────────────────────────────────────────────────────┤
│ │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ │
│ │ Terraform/ │ │ Ansible/ │ │ Kubernetes │ │
│ │ OpenTofu │ │ Automation │ │ Operators │ │
│ └──────┬───────┘ └──────┬───────┘ └──────┬───────┘ │
│ │ │ │ │
│ ┌──────┴──────────────────┴──────────────────┴───────┐ │
│ │ O8 Orchestration Layer │ │
│ │ ┌────────────────────────────────────────────┐ │ │
│ │ │ Secrets Management (Current) │ │ │
│ │ │ • AWS Secrets Manager │ │ │
│ │ │ • GCP Secret Manager │ │ │
│ │ │ • External Secrets Operator │ │ │
│ │ └────────────────────────────────────────────┘ │ │
│ │ ┌────────────────────────────────────────────┐ │ │
│ │ │ Infrastructure Provisioning │ │ │
│ │ │ • Compute (EC2, GCE, AKS, EKS, GKE) │ │ │
│ │ │ • Networking (VPC, Subnets, Firewalls) │ │ │
│ │ │ • Storage (S3, GCS, Block Storage) │ │ │
│ │ └────────────────────────────────────────────┘ │ │
│ │ ┌────────────────────────────────────────────┐ │ │
│ │ │ Configuration Management │ │ │
│ │ │ • Service Discovery │ │ │
│ │ │ • Dynamic Configuration │ │ │
│ │ │ • Feature Flags │ │ │
│ │ └────────────────────────────────────────────┘ │ │
│ └──────────────────────────────────────────────────┘ │
│ │
│ ┌─────────────────────────────────────────────────────────┐ │
│ │ GitOps Integration │ │
│ │ • ArgoCD Applications │ │
│ │ • Flux CD │ │
│ │ • GitHub Actions / GitLab CI │ │
│ └─────────────────────────────────────────────────────────┘ │
└─────────────────────────────────────────────────────────────────┘

Integration Points

1. Infrastructure as Code (IaC) Integration

Terraform/OpenTofu Provider

# terraform/providers.tf
terraform {
required_providers {
o8 = {
source = "orchestr8/orchestr8"
version = "~> 1.0"
}
}
}

provider "orchestr8" {
project = "orchestr8-468414"
region = "us-east-1"
}

# Use O8 to manage secrets
resource "orchestr8_secret" "database" {
name = "production-database"
provider = "gcp"

data = {
host = aws_db_instance.main.endpoint
port = aws_db_instance.main.port
username = aws_db_instance.main.username
password = random_password.db.result
}
}

# Reference in Kubernetes via External Secrets
resource "kubernetes_manifest" "database_secret" {
manifest = {
apiVersion = "external-secrets.io/v1beta1"
kind = "ExternalSecret"
metadata = {
name = "database-credentials"
namespace = "production"
}
spec = {
secretStoreRef = {
name = "orchestr8-gcp-store"
kind = "SecretStore"
}
target = {
name = "database-credentials"
}
data = [{
secretKey = "connection-string"
remoteRef = {
key = orchestr8_secret.database.id
}
}]
}
}
}

2. CI/CD Pipeline Integration

GitHub Actions

# .github/workflows/deploy.yml
name: Deploy Infrastructure
on:
push:
branches: [main]

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Setup O8
run: |
pip install orchestr8
o8 secrets setup --provider gcp --key-file ${{ secrets.GCP_KEY }}

- name: Create Application Secrets
run: |
# Generate random passwords
API_KEY=$(openssl rand -hex 32)
JWT_SECRET=$(openssl rand -hex 64)

# Store in O8
o8 secrets create app-${{ github.sha }} \
--provider gcp \
--data "api_key=$API_KEY,jwt_secret=$JWT_SECRET"

- name: Deploy with Terraform
run: |
terraform init
terraform apply -auto-approve \
-var="secret_ref=app-${{ github.sha }}"

3. Service Mesh Integration

Istio + O8

# istio-secret-sync.yaml
apiVersion: batch/v1
kind: CronJob
metadata:
name: istio-cert-sync
spec:
schedule: "0 */6 * * *" # Every 6 hours
jobTemplate:
spec:
template:
spec:
containers:
- name: cert-syncer
image: orchestr8/orchestr8-cli:latest
command:
- /bin/sh
- -c
- |
# Fetch TLS certs from O8
o8 secrets get istio-tls-certs --provider gcp \
--output json > /tmp/certs.json

# Update Istio Gateway
kubectl create secret tls istio-ingressgateway-certs \
--cert=/tmp/tls.crt \
--key=/tmp/tls.key \
--dry-run=client -o yaml | kubectl apply -f -

4. Multi-Cloud Resource Management

# orchestr8_cim_integration.py
from orchestr8_orchestrator import O8
from typing import Dict, Any
import boto3
from google.cloud import compute_v1
from azure.mgmt.compute import ComputeManagementClient

class CloudInfrastructureManager:
"""Complete CIM solution using O8 for secrets"""

def __init__(self):
self.orchestr8 = O8()
self._init_providers()

def _init_providers(self):
"""Initialize cloud providers using O8 secrets"""
# Fetch cloud credentials from O8
aws_creds = self.orchestr8.secrets.get("cloud-credentials/aws")
gcp_creds = self.orchestr8.secrets.get("cloud-credentials/gcp")
azure_creds = self.orchestr8.secrets.get("cloud-credentials/azure")

# Initialize providers
self.aws = boto3.Session(
aws_access_key_id=aws_creds['access_key'],
aws_secret_access_key=aws_creds['secret_key']
)
self.gcp = compute_v1.InstancesClient(
credentials=gcp_creds['service_account']
)
self.azure = ComputeManagementClient(
credential=azure_creds['credential'],
subscription_id=azure_creds['subscription_id']
)

def provision_infrastructure(self, config: Dict[str, Any]):
"""Provision infrastructure across clouds"""
environment = config['environment']

# Store infrastructure state in O8
state_key = f"infrastructure/{environment}/state"

# Provision resources
resources = {
'aws': self._provision_aws(config['aws']),
'gcp': self._provision_gcp(config['gcp']),
'azure': self._provision_azure(config['azure'])
}

# Store resource IDs and connection info in O8
for cloud, resource_info in resources.items():
self.orchestr8.secrets.create(
f"infrastructure/{environment}/{cloud}",
data=resource_info,
provider="gcp" # Use GCP as primary secret store
)

# Create Kubernetes secrets via External Secrets
self._sync_to_kubernetes(environment, resources)

return resources

def _sync_to_kubernetes(self, env: str, resources: Dict):
"""Sync infrastructure details to Kubernetes"""
# Generate External Secret manifests
for cloud, info in resources.items():
external_secret = {
"apiVersion": "external-secrets.io/v1beta1",
"kind": "ExternalSecret",
"metadata": {
"name": f"{cloud}-resources",
"namespace": env
},
"spec": {
"secretStoreRef": {
"name": "orchestr8-store",
"kind": "ClusterSecretStore"
},
"target": {
"name": f"{cloud}-resources"
},
"dataFrom": [{
"extract": {
"key": f"infrastructure/{env}/{cloud}"
}
}]
}
}
# Apply to cluster
self._apply_manifest(external_secret)

Complete CIM Commands via O8

# Initialize CIM with O8
o8 cim init --providers aws,gcp,azure

# Provision infrastructure
o8 cim provision --config infrastructure.yaml --env production

# Manage secrets across all infrastructure
o8 cim secrets rotate --all --older-than 30d

# Backup all secrets and state
o8 cim backup --output s3://backups/cim/

# Disaster recovery
o8 cim restore --from s3://backups/cim/latest

# Cost optimization
o8 cim analyze costs --recommend-savings

# Compliance scanning
o8 cim compliance scan --standards "SOC2,HIPAA,PCI-DSS"

# Infrastructure drift detection
o8 cim drift detect --auto-remediate

1. Pulumi Integration

import * as o8 from "@orchestr8/orchestr8";

const secretStore = new orchestr8.SecretStore("main", {
provider: "gcp",
project: "orchestr8-468414"
});

const dbPassword = new orchestr8.Secret("db-password", {
store: secretStore,
data: {
password: pulumi.secret(randomPassword.result)
}
});

2. Crossplane Integration

apiVersion: o8.orchestr8.io/v1alpha1
kind: SecretStore
metadata:
name: crossplane-secrets
spec:
provider: gcp
projectID: orchestr8-468414
---
apiVersion: database.crossplane.io/v1beta1
kind: PostgreSQLInstance
spec:
forProvider:
passwordSecretRef:
name: database-password
namespace: crossplane-system
key: password
writeConnectionSecretToRef:
name: database-connection
namespace: default

3. Backstage Integration

# app-config.yaml
catalog:
providers:
orchestr8:
baseUrl: https://orchestr8.platform.io
auth:
provider: oauth2

integrations:
orchestr8:
- host: orchestr8.platform.io
apiBaseUrl: https://api.o8.platform.io
token: ${O8_TOKEN}

# Backstage template
apiVersion: scaffolder.backstage.io/v1beta3
kind: Template
metadata:
name: microservice-template
spec:
steps:
- id: create-secrets
name: Setup Secrets
action: orchestr8:create-secrets
input:
provider: gcp
secrets:
- name: ${{ parameters.name }}-db
- name: ${{ parameters.name }}-api-keys

Benefits of O8-Powered CIM

  1. Unified Secret Management: All infrastructure secrets in one place
  2. Multi-Cloud Native: First-class support for AWS, GCP, Azure
  3. GitOps Ready: Designed for declarative infrastructure
  4. Compliance Built-in: Audit trails, rotation, encryption
  5. Developer Friendly: Simple CLI, SDKs in multiple languages
  6. Kubernetes Native: External Secrets Operator integration
  7. Cost Optimization: Track and optimize secret storage costs
  8. Disaster Recovery: Built-in backup and restore capabilities

Next Steps for Full CIM

  1. Add Resource Provisioning: Extend O8 to manage compute, network, storage
  2. State Management: Implement Terraform-like state management
  3. Policy Engine: Add OPA/Rego for policy enforcement
  4. Cost Management: Integrate with cloud billing APIs
  5. Observability: Add metrics, logs, traces for all operations
  6. Workflow Engine: Add Temporal/Argo Workflows for complex operations
  7. UI Dashboard: Build web UI for visual management

This positions O8 as the foundation for a complete enterprise CIM solution that can compete with tools like HashiCorp's suite, while being more cloud-native and Kubernetes-focused.