Defang Documentation
website·Indexed 34 days ago
https://docs.defang.ioAn AI-assisted deployment tool that transforms Docker Compose files into secure, scalable cloud deployments. Defang supports multiple providers including AWS, GCP, Azure, and DigitalOcean, and offers features such as 1-Click Deploy, GitHub Actions integration, and an MCP Server for automated service deployment.
What's inside Defang
- Defang Deploy is a platform designed to streamline the development, deployment, and debugging of cloud applications. It supports a wide range of use cases including web services, APIs, mobile app backends, ML services, and LLM hosting. It is language-agnostic, supporting Node.js, Python, Golang, and any application that can be packaged in a Dockerfile.
Overview of Defang Deploy capabilities
Defang Deploy allows developers to transition applications from Docker Compose to secure, scalable cloud deployments. It automates the configuration of networking, security, and observability, and supports zero-downtime updates. The platform supports the following cloud providers via the Bring-your-Own-Cloud (BYOC) model:
- Amazon Web Services (AWS)
- DigitalOcean
- Google Cloud Platform (GCP)
- Microsoft Azure
For stateful workloads, Defang provides managed storage options including Managed Postgres and Managed Redis. Users can also integrate their own custom domain names.
Overview of Defang Platform
Defang is a platform designed to help developers become AI-native while maintaining control over their own cloud infrastructure, models, and accounts, avoiding vendor lock-in.Overview of Defang Deploy
Defang Deploy is a tool that allows developers to transition applications from Docker Compose to secure, scalable cloud deployments. It supports applications built in any language or stack, enabling deployment to a user's cloud account via a single command and providing AI-assisted tooling for rapid iteration.Understand Defang Workspace creation via GitHub/GitLab
When authorizing Defang to access GitHub or GitLab organizations, Defang automatically creates workspaces for each organization. Workspace membership is synchronized with the corresponding GitHub or GitLab organization membership. The first user to log in with a specific organization is automatically assigned as the workspace owner.Use one-off jobs for deployment tasks
One-off jobs (also known as release tasks) in Defang are commands that run a single time at specific points in the deployment process. If a one-off job fails, the entire deployment fails. Common use cases include database migrations, warming or cleaning caches, and running build scripts.Understand Defang BYOC logging architecture
In Defang BYOC (Bring Your Own Cloud) configurations, service output is logged directly to the native logging tools of the configured cloud provider. The Defang CLI retrieves and tails this output as needed.Understand Defang Workspace types
Workspaces organize teams and manage billing contexts in Defang. There are three types:
- Personal Workspace: Automatically created upon account signup using the username. It cannot be deleted or have additional members and serves as the default workspace.
- Defang-Managed Workspaces: Created via the Defang Portal. These can be renamed or deleted by the owner and support member invitations via links.
- Provider-Managed Workspaces: Automatically created when authorizing GitHub or GitLab organizations. Membership is managed through the Git provider. These cannot be deleted unless the organization is disconnected from Defang.
Deploy Defang services using Bring-Your-Own-Cloud (BYOC)
Defang allows you to deploy services directly into your own cloud accounts, a model referred to as Bring-Your-Own-Cloud (BYOC). Defang currently supports the following cloud providers for deployment: AWS, Azure, DigitalOcean, and GCP.Manage workspace recipes with the Defang CLI
Thedefang recipecommand (and its aliasesrecipes,modes, ormode) is used to manage workspace deployment modes. It provides subcommands to activate, deactivate, list, and show details of recipes within a workspace.Understand Defang workspace organization
Upon account creation, a personal workspace is automatically generated. Workspaces are used by Defang to organize teams and manage billing. While you can create additional workspaces or link them to GitHub or GitLab organizations, personal workspaces are restricted to a single member and cannot have additional members added.Provision managed storage services with Defang
Defang allows you to provision managed services to store and persist data for your scalable services. Supported managed storage types include caches (Redis), SQL databases (Postgres), NoSQL databases (MongoDB), and object storage.