Skip to content

syscode-labs/oci-free-tier-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

87 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OCI Free Tier Manager

License: MIT CI OpenTofu OCI Free Tier

OpenTofu infrastructure for OCI Always Free tier — provisions 4× Ampere A1.Flex (ARM64) + 1× Micro instance.

Supports two modes via the omni_ready toggle:

Mode omni_ready OS Kubernetes
Default false Ubuntu (custom image) Bring your own
Talos + Omni true Talos Linux Enrolled into Omni via SideroLink

Structure

tofu/oci/       OpenTofu module — instances, networking, budget
scripts/        Helper scripts (state backend, capacity check)

Quick Start

Prerequisites

  • OCI account (PAYG recommended for Ampere availability)
  • OCI CLI configured (~/.oci/config)
  • OpenTofu ≥ 1.8

Configure

cp tofu/oci/terraform.tfvars.example tofu/oci/terraform.tfvars
# Edit terraform.tfvars — set compartment OCID, SSH key, image OCIDs

Key variables:

# Default (Ubuntu)
omni_ready = false

# Talos + Omni enrollment
omni_ready       = true
talos_image_ocid = "ocid1.image.oc1..."   # auto-fetched from oci-talos-gitops-apps in CI
omni_endpoint    = "omni.example.com:8090"
omni_join_token  = "..."                  # or pass via -var / TF_VAR_omni_join_token

Deploy

cd tofu/oci
tofu init
tofu plan
tofu apply

Talos Mode

When omni_ready = true:

  1. Nodes boot Talos Linux (custom OCI image from oci-free-tier-images)
  2. user_data injects a Talos MachineConfig that joins Omni via SideroLink
  3. Omni detects the nodes and provisions the cluster
  4. Argo CD GitOps is managed by oci-talos-gitops-apps

OCI Free Tier Resources

Compute

  • Ampere A1: 4 OCPUs + 24 GB RAM total (ARM64, flexible — split across up to 4 instances)
  • E2.1.Micro: 2 instances × 1/8 OCPU + 1 GB RAM (AMD)

Storage

  • Block volumes: 200 GB total (includes all boot volumes)
  • Object storage: 20 GB

Networking

  • VCNs: 2
  • Load balancer: 1 (10 Mbps)
  • Egress: 10 TB/month

Troubleshooting

"Out of capacity" for Ampere

Normal — Ampere instances are highly contested. The CI deploy workflow retries automatically. For manual deployments:

  • Re-run tofu apply — OCI eventually allocates capacity
  • Try a different availability domain within the same region
  • Try off-peak hours

Storage limit exceeded

200 GB includes all boot volumes. Example allocations:

  • 4× Ampere at 47 GB = 188 GB (leaves 12 GB)
  • 3× Ampere + 1× Micro at 50 GB = 200 GB (maxed)

Related Repositories

License

MIT License

About

A comprehensive toolkit for maximizing Oracle Cloud Infrastructure (OCI) Always Free tier resources.

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors