Skip to content

ContainerCraft/pulumi-deployments-iac

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pulumi Cloud Deployments

  • TTL Stacks
  • Scheduled Deployments
  • Drift Detection

Getting Started

  1. Add PULUMI_ACCESS_TOKEN secret to Github Codespaces Secrets
  2. Add CIVO API Key secret to Pulumi stack Config or Pulumi ESC
  3. Open repository in Github Codespaces
  4. Login and create a new Pulumi stack
pulumi login
pulumi org set-default ContainerCraft
pulumi stack select --create dev
vim pulumi/stacks/Pulumi.dev.yaml
  1. For Pulumi ESC, add your CIVO environment to pulumi/stacks/Pulumi.dev.yaml:
environment:
  - civo
  1. Configure deployment settings

NOTE: First deploy with Pulumi Cloud DeploymentSettings disabled since our stack needs to be created before we can deploy Pulumi Cloud stack deployments configuration.

# Pulumi Project IaC specific settings

# Enable CIVO Infrastructure Deployment
pulumi config set civo_kubernetes.deploy true

# Enable Pulumi Cloud Stack Deployments Configuration
pulumi config set pulumicloud.deployment true

# Enable Pulumi Cloud Stack Deployments:
# - Pulumi Preview Deployments Schedule
pulumi config set pulumicloud.schedule true
  1. Deploy the stack
pulumi preview
pulumi up
  1. Destroy the stack
pulumi destroy --refresh=true --skip-preview -y
pulumi stack rm dev

Tips

# Load the kubeconfig locally for kubectl cli usage
mkdir ~/.kube && pulumi stack output kubeconfig --show-secrets > ~/.kube/config

# Try a kubectl command like this to list all pods
kubectl get po -A

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks