> ## Documentation Index
> Fetch the complete documentation index at: https://docs.skyhook.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Skyhook exec

## skyhook exec

Execute a command in a pod

### Synopsis

Execute a command in a running pod.

Opens an interactive shell by default. Uses your current kubectl context.

Environment variables:
SKYHOOK\_ORG       Default organization
SKYHOOK\_SERVICE   Default service (or use .koala.toml)
SKYHOOK\_ENV       Default environment (or use 'skyhook config set env')

```
skyhook exec [-- command] [flags]
```

### Examples

```
  skyhook exec                              # Interactive shell in pod
  skyhook exec --env prod                   # Shell in production pod
  skyhook exec -- /bin/sh                   # Specific shell
  skyhook exec -- ls -la                    # Run command and exit
  skyhook exec --first --env dev -- whoami  # Non-interactive: auto-select first pod
```

### Options

```
  -c, --container string   Container name
      --context string     Kubernetes context to use
  -e, --env string         Environment
      --first              Auto-select first available pod (non-interactive)
  -h, --help               help for exec
  -p, --pod string         Specific pod name
  -s, --service string     Service to exec into
```

### Options inherited from parent commands

```
      --debug        Enable debug mode (shows full API requests/responses)
  -o, --org string   Organization name
  -v, --verbose      Enable user-friendly verbose output
```

### SEE ALSO

* [skyhook](/cli-reference/skyhook)	 - skyhook is a CLI tool to help you create and manage k8s services
