CLI Reference
The Beam CLI is the primary way youβll interact with the Beam runtime.
You can use the --help
flag to get information about any command.
Setup Credentials
Login
Automatically add your API keys to your local machine.
This command will open the Beam dashboard in your web browser and fire a callback that saves your Beam credentials to your local machine.
Config
Configures your Beam API keys and saves a profile to ~/.beam/config.ini
Context Name
(required) β the name of the profile i.e. prod or staging.Gateway Host
(optional) β used only for self-hosting. If you are using the beam.cloud, you can leave this blank.Gateway Port
(optional) β used only for self-hosting. If you are using the beam.cloud, you can leave this blank.Token
(required) β your API token, found on this page of the dashboard.
Create
Create a new context.
If you are prompted to enter a value for Gateway Host
or Gateway Port
, you
can leave both fields blank.
Delete
Delete a saved context.
List
Lists saved contexts.
Select
Set the default context.
Deployment
Create
Deploys your app and creates a persistent web endpoint to access it.
You can run this command with beam deploy [...]
or beam deploy create [...]
.
List
Lists all deployments.
Stop
Stops a deployment.
Delete
Deletes a deployment.
Serve
Create a Preview Environment
Creates a temporary deployment preview.
Container
Manage the containers running in your account.
List
Lists all containers.
Stop
Terminate a running container.
Task
Any code you run on Beam creates a task. Any time you run a function or invoke an API, a task is created.
List Tasks
Lists all tasks.
Stop a Task
Stops a task.
Volume
Beam allows you to create highly-available storage volumes that can be used across tasks. You might use volumes for things like storing model weights or large datasets.
Create a Volume
Creates a volume.
Delete a Volume
List Volumes
List all volumes mounted to your apps.
List Volume Contents
List all contents of a volume.
Copy Files to Volumes
Copies a file to a volume.
Move Files in Volumes
Move files around a volume.
Remove Files from Volumes
Remove a file from a volume.
Secret
Secrets and environment variables can be injected into the containers that run your apps. After a secret is saved, it can be used in your application code like this:
List Secrets
Lists all secrets that exist.
Create a Secret
Creates a secret
Show a Secret
Shows the value of a secret.
Modify a Secret
Modifies the value of a secret.
Delete a Secret
Permanently deletes a secret.
Logs
You can stream logs from a task, deployment, or a container to your shell.
Deployment
Streams logs for a deployment.
You can find the deployment ID by running beam deployment list
.
Task
Streams logs for a task.
You can find the task ID by running beam task list
.
Container
Streams logs for a container.
You can find the container ID by running beam container list
.
Stub ID
Streams logs for a stub ID.
Machine
Manage the machines available on Beam.
List
List the available GPUs at any given moment.
Helpers and utils
Ignore Local Files
You can create a .beamignore
file in your projectβs root directory to tell Beam which local files and directories to ignore when syncing to Beam.
This follows the conventions of .gitignore
Ignoring Files
Ignoring Folders
Was this page helpful?