atmos.yaml2.0 KB
View on GitHubbase_path: "./"
components:
kubernetes:
base_path: "components/kubernetes"
provider: kubectl
# Managed Git repositories for GitOps delivery. A Kubernetes component can render
# its manifests and publish them to one of these repositories (instead of applying
# to a cluster) via `provision.targets` with `kind: git`. Argo CD or Flux then
# reconciles the repository. Replace the URI with your deployment repository.
git:
repositories:
deployments:
uri: https://github.com/acme/deployments.git
branch: main
stacks:
base_path: "stacks"
included_paths:
- "deploy/**/*"
excluded_paths:
- "**/_defaults.yaml"
name_template: "{{.vars.stage}}"
logs:
file: "/dev/stderr"
level: Info
# The `local-k3s` identity binds the component to a local Kubernetes emulator. Atmos
# starts the k3s container (`atmos emulator up kubernetes -s dev`), harvests its
# admin kubeconfig, and injects KUBECONFIG into the component environment — no
# docker-compose, no mixin, no manual kubeconfig wiring. The bound emulator is the
# `components.emulator.kubernetes` component (see stacks/catalog/emulator/kubernetes.yaml).
auth:
identities:
local-k3s:
kind: kubernetes/emulator
emulator: kubernetes
# For real EKS clusters, wire Atmos Auth to Kubernetes by adding an aws/eks
# integration to the identity used by the component command.
#
# integrations:
# prod-eks:
# kind: aws/eks
# via:
# identity: platform-admin
# spec:
# cluster:
# name: acme-prod-eks
# region: us-east-1
# alias: acme-prod
# kubeconfig:
# path: /tmp/acme-prod-kubeconfig
# update: replace
commands:
- name: "test"
description: "Bring up the local Kubernetes emulator, apply the demo, then tear it down"
steps:
- atmos validate stacks
- atmos emulator up kubernetes -s dev
- atmos kubernetes apply demo -s dev --identity local-k3s
- atmos emulator down kubernetes -s dev