coolify
Manage Coolify instances
SYNOPSIS
coolify-cli command [options]
PARAMETERS
command
The specific operation to perform. Common commands include deploy, restart, logs, status, and ssh.
deploy
Deploys a specified project and environment. This command initiates the build and deployment process defined within your Coolify instance. Requires --project and --environment options.
restart
Restarts all services associated with a given project and environment. Useful for applying configuration changes or resolving issues. Requires --project and --environment options.
logs
Fetches and displays real-time logs for a project's services. Requires --project and --environment options. An additional --follow option can stream logs as they are generated.
status
Shows the current status of services within a specified project and environment, indicating if they are running or stopped. Requires --project and --environment options.
ssh
Establishes an SSH connection to a running container of the specified project and environment, enabling direct debugging or command execution. Requires --project and --environment options.
--project=<id>
Mandatory option for most commands, specifying the unique identifier of the project to act upon. This ID is found in your Coolify web interface.
--environment=<name>
Mandatory option for most commands, specifying the name of the environment (e.g., 'production', 'staging') within the project.
DESCRIPTION
Coolify is an open-source, self-hosting platform designed to simplify the deployment and management of web applications, databases, and services on your own server. It offers an alternative to services like DigitalOcean App Platform or Heroku, giving users full control over their infrastructure.
The coolify command, typically invoked as coolify-cli, serves as the command-line interface for interacting with your Coolify instance. It allows developers and administrators to perform common tasks such as initiating deployments, restarting services, viewing logs, and accessing application containers via SSH, all from the terminal. This CLI tool complements the platform's comprehensive web interface, enabling automation and script-based management workflows for your self-hosted projects. It's particularly useful for integrating Coolify operations into CI/CD pipelines or for quick administrative actions without navigating the web UI.
CAVEATS
The coolify-cli requires a running Coolify server instance to connect to and manage. It also necessitates proper authentication configured via API keys or session tokens. Project and environment IDs/names must accurately correspond to those configured on your Coolify server. Network connectivity to the Coolify server is essential for the CLI to function. The exact syntax and available commands may evolve with new versions of Coolify and its CLI.
INSTALLATION
To install the coolify-cli, users typically follow the instructions provided on the official Coolify documentation or GitHub repository. This often involves downloading a pre-compiled binary for your specific operating system (Linux, macOS, Windows) or building the tool from source code. Once the executable is obtained, it needs to be placed in a directory included in your system's PATH for easy access.
AUTHENTICATION
Before using coolify-cli, you must authenticate it with your Coolify server instance. This is commonly achieved by generating an API key from your Coolify web interface. The CLI tool then needs to be configured with this key and the URL of your Coolify server, often through environment variables (e.g., COOLIFY_SERVER_URL, COOLIFY_API_KEY) or a configuration file. This secure setup ensures that the CLI can interact with your projects and resources on the server.
HISTORY
The coolify-cli tool was developed by Coollabs, the creators of the Coolify self-hosting platform. It emerged as an extension to the core platform, aiming to provide a more streamlined and automated way to interact with Coolify instances from the command line. Its development is ongoing, evolving with the platform to offer comprehensive management capabilities for self-hosted applications and services. It became a crucial component for headless operations and CI/CD integration.


