Environments
Categories:
Environments are how you organize your deployment targets (whether on-premises servers or cloud services) into groups that represent the different stages of your deployment pipeline, for instance, development, test, and production. Environments allow you to logically group related Connections and their associated Credentials. Environments make it easier for you to manage, share, and work with a collection of resources as a group, instead of dealing with all your Connections and Credentials on an individual basis.
Looking for Practical Environment Management?
For step-by-step instructions on how to view, create, and edit environments, and how to assign connections to an environment or remove them from it, see the Managing Environments guide.Assigning Resources to Environments π
Assign any number of Connections to an environment whether that Connection is managed or unmanaged (see MeshSync to learn more about managed and unmanaged Connections). In-turn, assign any number of Environments to one or more Workspaces. Connections (and any associated Credentials) that are assigned to an Environment become immediately available for use in any associated Workspace.
Sharing Resources between Environments π
Environments can share resources. For example, you might create an environment named “production” and assign three connections: a GitHub connection, a Kubernetes connection, and a Prometheus connection. Subsequently, you also define an environment named “dev/test” and assign three connections: a different Kubernetes connection, a different Prometheus connection, and the same GitHub connection that is also assigned to the “production” environment.
Deleting an Environment π
Deleting an environment does not delete any resources (e.g. connections) currently contained in the environment. Resources that belong to other environments will continue to belong to those other environments. Learn more about the behavior of lifecycle of connections. For the steps themselves, see Delete an Environment.
Summary π
Environments represent a collection of resources in the form of Connections - both of managed and unmanaged Connections. Environment resources are comprised of Connections (and implicitly any Credentials used by those assigned Connections). Create and use environments to organize your connections and credentials into groups, and then make these resources available to you and your teams by assigning environments to Workspaces.
Key Features π
Logical Grouping Environments allow you to logically group related connections and their associated credentials. This makes it easier to manage, share, and work with a subset of resources instead of dealing with all your connections individually.
Resource Sharing Environments can be seamlessly assigned to Workspaces, another essential concept in Meshery. When you assign an Environment to a Workspace, you enable resource sharing among team members. This collaborative approach simplifies the sharing of connections and resources, making it easier to work together in cloud native environments.
Key Components π
Connections π
Connections are an integral part of Environment. These are cloud native resources that can be both managed and unmanaged, and they’re registered by the Meshery Server. Examples of connections include Kubernetes clusters, Prometheus instances, Jaeger tracers, and Nginx web servers.
See “Connections” in Meshery Docs for more information.
Credentials π
Credentials in an Environment are the keys to securely authenticate and access managed connections. For example, valid Prometheus secrets or Kubernetes API tokens are essential credentials for securely interacting with these managed resources.
See “Credentials” in Meshery Docs for more information.
Access Control for Connections and Credentials π
Access to a Connection β and therefore to its associated Credentials β is granted through any of the following, evaluated independently:
- Direct ownership β the Connection’s owner (User ID) matches the current user’s ID. Ownership grants full read and write access, including deleting the Connection and its Credentials.
- Indirect access through a shared Workspace β the Connection is assigned to an Environment linked to a Workspace, and the current user belongs to a Team with access to that Workspace. This grants read-only access; Team membership alone does not grant the right to modify or delete the Connection or its Credentials.
- The “View All Organizations” key β a user holding this key can access every Connection and Credential across all organizations, bypassing the ownership and Team checks above.
Designs and Views are governed by a separate mechanism β resource-access mappings β rather than inheriting through Workspace/Team membership. See Identity and Security β Security Boundaries for how these mechanisms fit together.
Example: Orbital Labs Environment Setup π
The following illustrates how Five and Zara set up multi-cloud environments at Orbital Labs, spanning AWS, GCP, and Azure. See Meet Five and the Cast for the full seed inventory.
Environment Inventory π
| Environment | Workspace | Cloud Provider | Connections |
|---|---|---|---|
prod-aws | orbital-production | AWS | EKS cluster, RDS (PostgreSQL), S3, CloudFront, SQS |
prod-gcp | orbital-production | GCP | GKE cluster, Cloud SQL, Cloud Storage, Pub/Sub |
staging-aws | orbital-staging | AWS | EKS cluster, S3, ElastiCache |
staging-azure | orbital-staging | Azure | AKS cluster, Azure Blob Storage, Azure Service Bus |
dev-local | orbital-dev | Local | kind (local Kubernetes), LocalStack (AWS emulation) |
stellar-enterprise | stellar-main | Azure | AKS, Azure SQL, Azure API Management, Azure AD |
Connecting prod-aws π
Five connects Orbital Labs’ primary AWS production environment to Layer5 Cloud:
- Navigate to Environments and click Create (see Create an Environment)
- Name it
prod-awsand save - Add connections one at a time β each connection is a discrete cloud resource:
- EKS cluster β the compute layer for deployed workloads
- RDS (PostgreSQL) β the managed database instance
- S3 bucket β object storage for design artifacts and state
- CloudFront distribution β CDN layer for the frontend
- SQS queue β async messaging between services
- Zara assigns
prod-awsto theorbital-productionworkspace, making all five connections available to Infrastructure team members
Adding prod-gcp for Multi-Cloud Coverage π
Five repeats the process for GCP to give Orbital Labs multi-cloud flexibility:
- Create environment
prod-gcp - Add connections:
- GKE cluster β Google Kubernetes Engine compute
- Cloud SQL β managed relational database on GCP
- Cloud Storage bucket β GCP object storage
- Pub/Sub topic β async messaging on GCP
- Zara assigns
prod-gcptoorbital-productionalongsideprod-aws
Both environments are now available to any design deployed within the orbital-production workspace.
dev-local for Getting Started
Thedev-local environment uses a local Kubernetes cluster (kind) and LocalStack to emulate AWS services β no cloud credentials required. If you are following along with these docs for the first time, start with dev-local in the orbital-dev workspace.