Skip to main content

Create Environments

Prerequisites

Before creating an environment, ensure the following are in place:

  • An active Kubernetes cluster is available.
  • A project has been created with the required services defined.
info

Environment variables can be added or edited during environment creation — you do not need to set them up in advance.


Step 1 — Environment Basic Details

  1. Navigate to Environments from the left menu.
  2. Click Add Environment in the top right corner.
  3. Fill in the basic details:
FieldDescription
ProjectSelect the application blueprint (project) to deploy.
Environment NameA unique name for the environment. Must be lowercase, alphanumeric, and may contain hyphens.
ClusterThe Kubernetes cluster where the environment will be deployed.
NamespaceThe Kubernetes namespace for the environment. Must be unique per cluster.
DNS ZoneThe DNS hosted zone used for SSL/TLS certificates and custom domains (Route53 or Cloudflare).
DescriptionOptional description for the environment.
LabelsOptional key-value pairs for categorization and guardrail policy matching.
Environment basic details

  1. Click Save and Next to proceed to the services configuration page.
note

The services available for configuration are populated from the project you selected.


Step 2 — Application Service Configuration

For each application service in your project, configure the following sections.

Source Configuration

Atmosly supports two source types for application services:

Git Repositories (CI/CD)

Build and deploy from source code. Atmosly will run the CI pipeline to build a Docker image and then deploy it.

FieldDescription
App NameUnique name for the service within this environment.
App SourceThe source code repository (pre-populated from the project).
BranchThe Git branch to build from.
Dockerfile PathPath to the Dockerfile in the repository (default: Dockerfile).
Build ContextThe build context directory for Docker.
Container RegistryWhere to push the built image (ECR, DockerHub, GCR, or GAR).
Enable CI/CDToggle to enable automatic builds and deployments on code push.

Container Registry (CD Only)

Deploy a pre-built container image directly — no CI pipeline needed.

FieldDescription
App NameUnique name for the service within this environment.
Container RegistrySelect from your connected registries (ECR, DockerHub, GCR, or GAR).
Image RepositoryThe container image name.
Image TagThe specific image tag to deploy.
tip

Use Container Registry source when your images are built externally (e.g., by a third-party CI system) and you only need Atmosly to handle the deployment.

Service source configuration

Environment Variables

Add key-value pairs to configure your application at runtime.

FeatureDescription
Key / Value pairsDefine environment variable names and their values.
Secret variablesMark sensitive values as secrets — they will be masked in the UI unless you have the View secret permission.
Build-time variablesVariables injected during the Docker image build (CI stage). Enable the Build Time flag per variable.
Runtime variablesVariables injected when the container starts (CD stage). Enable the Run Time flag per variable. A variable can be both build-time and runtime.
Cross-service referencesA variable's value can depend on another service's output. Use the Depends On field to reference a datasource or application service — for example, to automatically inject a database connection string.
Bulk operationsSelect multiple variables for bulk delete.
Import / ExportImport variables from another deployment or export current variables as a file.
Environment variables

Secret Manager Integration

Atmosly supports syncing environment variables with external secret managers. Secret manager integration is configured at the project level and applies to all environments under that project.

Supported providers:

ProviderDescription
AWS Secrets ManagerSecrets stored and retrieved from AWS Secrets Manager in the configured region.
GCP Secret ManagerSecrets stored and retrieved from Google Cloud Secret Manager in the configured project.

How it works:

  1. Connect a secret manager to the project from the Project Settings page by selecting the cloud account and region.
  2. When creating or updating environment variables, mark sensitive values as Secret.
  3. Secret variables are automatically synced to the connected secret manager in the cloud.
  4. When fetching environment variables, secret values are retrieved from the cloud provider in real-time.
  5. Each variable tracks its sync status (synced or not synced) with the secret manager.

Disconnecting a secret manager removes all secret variable references from the cloud provider and converts them back to local storage.

info

To view secret values in the UI, your role must have the View secret permission. Without it, secret values appear masked as *****.

warning

Disconnecting a secret manager from a project affects all environments under that project. Secret variables will no longer be synced to or fetched from the cloud provider.

Deployment Configuration

Applications can be deployed using two methods:

  1. Visual — Configure deployment settings through the Atmosly UI form.
  2. YAML — Provide a raw Kubernetes YAML manifest for advanced configurations.

YAML Deployment Types

When using YAML mode, select the workload type:

TypeDescription
DeploymentStandard Kubernetes Deployment for stateless applications.
Job & CronJobOne-time or scheduled batch workloads.
StatefulSetFor stateful applications that require persistent storage and stable network identities.
Deployment options

YAML editor

tip

Use the Validate K8s YAML button to perform a Kubernetes dry-run validation — it checks for syntax errors and resource conflicts before deploying.

YAML Special Variables

When using YAML deployment mode, the following variables are automatically available and injected by Atmosly:

VariableDescription
$CI_SERVICE_IMAGEThe container image built and pushed by the CI pipeline. Use this to reference the latest image in your YAML.
$CI_SERVICE_NAMESPACEThe Kubernetes namespace of the current environment.
env[]The environment variables array configured for the service — automatically injected into the pod spec.

Import Environment Variables from Repository

You can import environment variables directly from .env files stored in your Git repository:

  1. In the Environment Variables section, click Import.
  2. Select the repository and branch.
  3. Atmosly will list the available .env files in the repository.
  4. Select a file to import its key-value pairs into the environment variables form.

This is useful for bootstrapping environment variables from your existing project configuration.

Networking & Ingress

FieldDescription
Service PortThe port your application listens on (0–65535).
Service TypeClusterIP (internal only), NodePort, or LoadBalancer.
Endpoint TypePublic (internet-accessible) or Private (internal network only).
Health Check PathHTTP endpoint for liveness and readiness probes (e.g., /health).
IngressEnable to expose the service via an ingress controller (NGINX or ALB).
PathThe URL path for routing traffic to this service (e.g., /).

Custom Domain

Enable a custom domain for your service:

FieldDescription
Custom DomainToggle to enable custom domain configuration.
Domain URLThe custom domain name (e.g., api.example.com).
DNS ZoneSelect the hosted zone (Route53 or Cloudflare).
HTTPSEnable HTTPS with automatic TLS certificate provisioning.
Networking configuration

Resource Limits

FieldDescription
CPU RequestMinimum CPU allocated to the service (in millicores, minimum 100m).
CPU LimitMaximum CPU the service can use (must be greater than or equal to the request).
Memory RequestMinimum memory allocated (in Mi, minimum 100Mi).
Memory LimitMaximum memory the service can use (must be greater than or equal to the request).
NodegroupThe node group where the service pods should be scheduled.

Horizontal Pod Autoscaler (HPA)

Enable auto-scaling to dynamically adjust the number of pods based on resource usage.

FieldDescription
Enable AutoscalingToggle to enable HPA.
Minimum ReplicasThe minimum number of pods to maintain.
Maximum ReplicasThe maximum number of pods to scale out to.
CPU ThresholdTarget CPU utilization percentage (1–100%) that triggers scaling.
Memory ThresholdTarget memory utilization percentage (1–100%) that triggers scaling.
Auto scaling configuration

Persistent Storage & Volumes

FieldDescription
Storage VolumeCreate a persistent volume with configurable size (minimum 5 Gi), mount path, and storage class.
ConfigMapsMount configuration files into the container. Specify name, mount path, filename, and file content.
Secrets (Files)Mount secret files into the container. Same structure as ConfigMaps but stored as Kubernetes Secrets.

Task Schedulers

FieldDescription
Cron JobsEnable scheduled tasks with a custom entry point command.
Queue WorkersEnable background queue processing with a custom entry point command.

Labels

Add custom key-value labels to your service for Kubernetes-level categorization and policy matching.


Step 3 — Datasource Configuration

If your project includes datasources (databases), configure them during environment creation.

Datasource Types

CategorySupported Databases
Self-ManagedMySQL, PostgreSQL, MongoDB, Redis, Kafka
AWS ManagedRDS MySQL, RDS PostgreSQL, Aurora MySQL, Aurora PostgreSQL, ElastiCache Redis
GCP ManagedCloud SQL and other GCP database services
Azure ManagedAzure database services
info

Self-managed databases are deployed as containers within the Kubernetes cluster. Cloud-managed databases are provisioned through the respective cloud provider's API.

Common Datasource Fields

FieldDescription
Display NameA human-readable name for the datasource.
TypeSelf-Managed or Cloud-Managed (AWS/GCP/Azure).
Database EngineThe database software (MySQL, PostgreSQL, MongoDB, Redis, Kafka, etc.).
VersionThe database version to deploy.
Storage SizeAllocated storage capacity (minimum 5 Gi).
ReplicasNumber of replica instances for high availability.
User Access DetailsDatabase username and credentials.
Auto-Generated PasswordToggle to automatically generate a secure password.
NodegroupThe node group for scheduling database pods (self-managed only).

Cloud-Managed Database Fields

FieldDescription
DB TypeSingle instance or Multi-AZ for high availability.
Storage TypeSSD or HDD storage tier.
Backup DetailsBackup frequency, retention period, and storage location.
Maintenance WindowScheduled time frame for automated maintenance.

Database Dump Support

For MySQL, PostgreSQL, and MongoDB datasources, you can import an initial data dump during creation:

DatabaseSupported Formats
MySQL / PostgreSQL.sql files (from S3 or direct upload)
MongoDB.gzip or .gz archive files

After Creation

Once created, you will be taken to the Environment Overview where you can monitor the status of all deployments.

Environment overview after creation

The Services Overview page shows the latest pipeline status for each service. Click on a pipeline to view its CI/CD logs.

Pipeline details

To view all pipelines for a service, navigate to the service under Service Overview and select the Pipelines tab.