Skip to content

Conversation

@llambeau
Copy link
Contributor

  • Add 'kubernetes' to executor types in schema
  • Add KubernetesConfig and ComponentKubernetesConfig to schema
  • Implement PodExecOperation for executing commands in K8s pods
  • Implement GetComponentPodOperation for resolving component to pod
  • Add resolveNamespace utility (CLI > K8S_NAMESPACE env > config > default)
  • Update MonorepoConfig to include kubernetes configuration

@llambeau llambeau force-pushed the feature/kubernetes-executor branch 5 times, most recently from fd3c931 to 32429f6 Compare January 29, 2026 13:47
This adds a new executor type that allows tasks to run on Kubernetes pods,
complementing the existing 'local' and 'container' (docker-compose) executors.

Features:
- New --executor kubernetes flag for `emb tasks run`
- Automatic pod and container discovery based on component configuration
- Configurable label selector via component kubernetes.selector
- Configurable default label via defaults.kubernetes.selectorLabel
- Namespace resolution: CLI flag > K8S_NAMESPACE env > config > 'default'
- Interactive task support with proper TTY handling
- SIGINT handling for graceful termination

New operations:
- GetComponentPodOperation: Resolves component to ready pod and container
- PodExecOperation: Executes commands in pods via WebSocket

Configuration (in .emb.yml):
  defaults:
    kubernetes:
      namespace: production
      selectorLabel: app.kubernetes.io/component  # default

  components:
    api:
      kubernetes:
        selector: app=custom-api  # override default selector
        container: main           # for multi-container pods

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@llambeau llambeau force-pushed the feature/kubernetes-executor branch from 32429f6 to 0bc91c0 Compare January 29, 2026 13:48
@llambeau llambeau merged commit abb24d0 into master Jan 29, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants