Aura CLI Cheat Sheet

Credentials and configurations

# Add credentials
# Add the --use flag if you want to use the credentials
aura credentials add --name <NAME> --client-id <YOUR_CLIENT_ID> --client-secret <YOUR_CLIENT_SECRET> --use

# List all credentials
aura credentials list


aura credentials current        # Show current credentials
aura credentials use <NAME>     # Use credentials with specified name
aura credentials delete <NAME>  # Delete credentials with specified name


# List all configured config options
aura config list

# Set config options
aura config set output table
aura config set default_tenant <PROJECT_ID>
aura config set save_logs true
aura config set log_file_path path/to/file.log

aura config get output      # Get a config option
aura config unset output    # Unset a config option

Projects

# List projects you are a member of
aura tenants list

# Get details about a project
aura tenants get --tenant-id <YOUR_PROJECT_ID>

# Get details about project metrics integration
aura tenants get-metrics-integration --tenant-id <YOUR_PROJECT_ID>

Instances

# List all instances
aura instances list

# List all instances belonging to a project
aura instances list --tenant-id <YOUR_PROJECT_ID>

# Get details of an instance
aura instances get --instance-id b65d4b4f
aura instances get --instance-name Production

# Create a new instance
aura instances create --name NewInstance --type enterprise-db --cloud-provider gcp --region europe-west1 --memory 4GB --tenant-id <YOUR_PROJECT_ID>
aura instances create --name NewInstance --type enterprise-ds --cloud-provider gcp --region europe-west1 --memory 8GB --tenant-id <YOUR_PROJECT_ID>
aura instances create --name Instance03 --type professional-db --cloud-provider aws --region us-east-2 --memory 16GB --tenant-id <YOUR_PROJECT_ID>

# Update an instance
aura instances update --instance-id b65d4b4f --new-name NewName
aura instances update --instance-id b65d4b4f --memory 8GB
aura instances update --instance-id b65d4b4f --new-name NewName --memory 8GB

# Delete an instance
aura instances delete --instance-id b65d4b4f

# Overwrite an instance
aura instances overwrite --instance-id b65d4b4f --source-instance a83d0l9
aura instances overwrite --instance-id b65d4b4f --source-instance a83d0l9 --source-snapshot 29428119-f7a4-49d8-bb18-3212ac98752e

# Pause and resume an instance
aura instances pause --instance-id b65d4b4f
aura instances pause --instance-name InstanceName
aura instances resume --instance-id b65d4b4f

# Wait for asynchronous operations
aura instances pause --instance-id b65d4b4f --wait
aura instances update --instance-id b65d4b4f --memory 8GB --wait

Snapshots

# List snapshot for an instance
aura snapshots list --instance-id b65d4b4f
aura snapshots list --instance-id b65d4b4f --date 2023-09-04

# Get a snapshot by id
aura snapshots get --instance-id b65d4b4f --snapshot-id 29428119-f7a4-49d8-bb18-3212ac98752e

# Create a new snpashot of an instance
aura snapshots create --instance-id b65d4b4f

# Restore a snapshot of an instance
aura snapshots restore --instance-id b65d4b4f --snapshot-id 29428119-f7a4-49d8-bb18-3212ac98752e

Useful flags

# Set the output format using the --output option
aura instances list --ouput table
aura instances list --ouput yaml

# Print verbose output using the --verbose flag
aura instances get -id b25d4b9f --verbose

# Print the response headers using the --include flag
aura YOUR_PROJECT_IDs list --include

# Show raw API output using the --raw flag
aura snapshots list --instance-id b25d4b9f --raw