Setup Infrastructure#

Prerequisites

Before setting up infrastructure for OSMO, ensure you have the prerequisites as specified in Cloud. This includes creating a VPC and subnets for the Kubernetes cluster, PostgreSQL database, and Redis instance.

Setup Options#

Option 2: Manually#

Note

Creating infrastructure manually requires familiarity with cloud resources and networking. Consider using the Terraform examples from Option 1 if you’re new to cloud infrastructure setup.

Follow the below guides to setup the infrastructure manually based on your cloud service provider of choice

Network (VPC/VNet)

Create isolated network infrastructure for your cloud resources.

Kubernetes Cluster

Deploy managed Kubernetes service to run OSMO Service components.

PostgreSQL Database

Create managed PostgreSQL database for application data storage.

Redis Cache

Set up managed Redis cache for session management and real-time data.

Configure Networking#

Required Network Connectivity

Ensure proper network connectivity between components for OSMO to function correctly.

Internal VPC Connections (Private Network):

  • Kubernetes ↔ PostgreSQL

  • Kubernetes ↔ Redis

External Connections:

  • Kubernetes → Cloud Storage (Outbound internet or VPC endpoint)

  • User → Kubernetes (Internet access via load balancer/ingress)

Best Practices#

  1. Use managed services: Cloud providers handle patching and updates

  2. Enable encryption: Encryption at rest and in transit for all services

  3. Private subnets: Keep databases and Redis in private subnets

  4. Minimal access: Use security groups to restrict access to only required ports

  5. Service accounts: Use cloud provider IAM for service-to-service authentication