What is a Flash environment?
mainAn environment is an isolated deployment context within a Flash app, acting as a separate "stage" (e.g., dev, staging, or production). Each environment is independent and contains its own:
- Deployed endpoints: Serverless endpoints provisioned from your
Endpointdefinitions. - Active build version: The specific version of your code running in that environment.
- Network volumes: Persistent storage for models, caches, etc.
- Deployment state: The current status (e.g.,
PENDING,DEPLOYING,DEPLOYED,FAILED).
Environments allow you to test changes in dev, validate in staging, and then promote to production without affecting other stages. Note that running flash deploy --env <name> will automatically create the environment if it does not already exist.
Flash App (my-project)
├── Environment: dev
│ ├── Build: build_v1
│ ├── Endpoints: [ep1, ep2]
│ └── Volumes: [vol1]
├── Environment: staging
│ ├── Build: build_v2
│ ├── Endpoints: [ep1, ep2]
│ └── Volumes: [vol1]
└── Environment: production
├── Build: build_v2
├── Endpoints: [ep1, ep2]
└── Volumes: [vol1]