Skip to content

SSH access

Connect directly to your environment containers using the Cloud CLI. SSH access uses AWS ECS Exec under the hood.

Terminal window
qc ssh

This opens an interactive bash shell in your environment container. If multiple containers are available, you’ll be prompted to select one.

FlagDescription
--container <name>Connect to a specific container (skip selection prompt)
--command <cmd>Run a command instead of opening an interactive shell
--interactiveForce interactive mode when used with --command
--org <org>Override organization
--app <app>Override application
--env <env>Override environment
--platform <platform>Override active platform
Terminal window
# Default: opens bash in the container
qc ssh
# Open a shell in a specific container
qc ssh --container=php
Terminal window
# Check PHP version
qc ssh --command="php -v"
# Run a database migration
qc ssh --container=php --command="php artisan migrate"
# Check disk usage
qc ssh --command="df -h"

Use --interactive with --command when you need an interactive shell other than bash:

Terminal window
# Open an interactive sh shell
qc ssh --container=php --command="/bin/sh" --interactive

Connect to a specific environment without changing your active context:

Terminal window
qc ssh --org=my-org --app=my-app --env=production

When a connection is established, the CLI displays:

  • Cluster — the ECS cluster name
  • Container — the container you’re connected to
  • Region — the AWS region
  • Expires — when the session credentials expire
  • Context — the org/app/env you’re connected to