Skip to content

@lastshotlabs/slingshot-infra

npm install @lastshotlabs/slingshot-infra

WebSocket scaling diagnostics — pure helper that inspects a runtime app config and returns scaling-related warnings/infos.

Designed to be merged into the output of slingshot infra check. The function is stateless and has no side effects.

function auditWebsocketScaling(config: AppConfigShape): WsScalingAuditResult

Source: packages/slingshot-infra/src/config/websocketScalingAudit.ts

Derives the uses resource list from a runtime app config object.

This is a best-effort heuristic that inspects the shape of a createApp() / createServer() config to determine which shared infrastructure resources the application needs. It is NOT a strict contract — users can always override with an explicit uses array in slingshot.infra.ts.

Usage in slingshot.infra.ts:

import { defineInfra, deriveUsesFromAppConfig } from '@lastshotlabs/slingshot-infra';
import appConfig from './src/appConfig';
export default defineInfra({
stacks: ['main'],
uses: deriveUsesFromAppConfig(appConfig),
});
function compareInfraResources(opts: { /** The `uses` array from slingshot.infra.ts (or empty) */ infraUses: string[]; /** The keys of `resources` from slingshot.platform.ts */ platformResources: string[]; /** Auto-derived uses from the app config (via deriveUsesFromAppConfig) */ derivedUses: string[]; }): InfraCheckDiagnostics

Source: packages/slingshot-infra/src/config/deriveUsesFromApp.ts

A computed deploy plan describing what runDeployPipeline() would change.

function computeDeployPlan(opts: ComputeDeployPlanOptions): DeployPlan

Source: packages/slingshot-infra/src/deploy/plan.ts

A single DNS record returned by the Cloudflare API.

function createCloudflareClient(config: { apiToken: string; zoneId?: string }): DnsClient

Source: packages/slingshot-infra/src/dns/cloudflare.ts

High-level DNS management interface used by the deploy pipeline.

Implementations are created by createDnsManager() based on the DnsProviderConfig.provider field: 'cloudflare' is fully implemented, 'manual' logs instructions without making API calls, and 'route53' throws on every method until implemented.

function createDnsManager(config: DnsProviderConfig): DnsManager

Source: packages/slingshot-infra/src/dns/manager.ts

Create a resource provisioner for Amazon DocumentDB (Mongo-compatible).

When config.provision is true, generates an SST config with aws.docdb.Cluster and aws.docdb.ClusterInstance Pulumi resources and runs bunx sst deploy. Outputs (host, port, username, password, database) are parsed from SST stdout. When provision is false, the config.connection map is returned as-is.

function createDocumentDbProvisioner(): ResourceProvisioner

Source: packages/slingshot-infra/src/resource/provisioners/documentdb.ts

Configuration options for the EC2/nginx (or Caddy) preset.

function createEc2NginxPreset(config?: Ec2NginxPresetConfig): PresetProvider

Source: packages/slingshot-infra/src/preset/ec2-nginx/ec2NginxPreset.ts

Configuration options for the ECS preset.

function createEcsPreset(config?: EcsPresetConfig): PresetProvider

Source: packages/slingshot-infra/src/preset/ecs/ecsPreset.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

function createEmptyRegistryDocument(platform: string): RegistryDocument

Source: packages/slingshot-infra/src/types/registry.ts

Create a resource provisioner for Apache Kafka (AWS MSK via Pulumi/SST).

When config.provision is true, generates an SST config with an aws.msk.Cluster Pulumi resource and runs bunx sst deploy. The bootstrap brokers string is parsed from SST stdout. When provision is false, the config.connection.brokers value is returned as-is.

function createKafkaProvisioner(): ResourceProvisioner

Source: packages/slingshot-infra/src/resource/provisioners/kafka.ts

Configuration for the local filesystem registry provider.

function createLocalRegistry(config: LocalRegistryConfig): RegistryProvider

Source: packages/slingshot-infra/src/registry/localRegistry.ts

Extended shared resource config for MongoDB Atlas provisioning.

Extends the base SharedResourceConfig with Atlas-specific project and organization identifiers. Credentials (ATLAS_PUBLIC_KEY, ATLAS_PRIVATE_KEY) must be present in environment variables at provision time.

function createMongoProvisioner(): ResourceProvisioner

Source: packages/slingshot-infra/src/resource/provisioners/mongo.ts

Create a resource provisioner for PostgreSQL (Aurora Serverless v2).

When config.provision is true, generates an SST config with an sst.aws.Postgres component and runs bunx sst deploy in a temporary directory. The outputs (host, port, user, password, database) are parsed from SST stdout and stored in the registry. When provision is false, the config.connection map is returned as-is.

function createPostgresProvisioner(): ResourceProvisioner

Source: packages/slingshot-infra/src/resource/provisioners/postgres.ts

Create an in-memory registry of preset providers keyed by name.

Throws immediately when an unknown preset name is requested so errors surface at deploy time rather than silently producing empty output.

function createPresetRegistry(presets: PresetProvider[]): void

Source: packages/slingshot-infra/src/preset/presetRegistry.ts

Create an in-memory registry of resource provisioners keyed by resource type.

Throws immediately when an unknown resource type is requested so errors surface at provision time rather than silently skipping resources.

function createProvisionerRegistry(provisioners: ResourceProvisioner[]): void

Source: packages/slingshot-infra/src/resource/provisionerRegistry.ts

Create a resource provisioner for Redis (ElastiCache Serverless via SST).

When config.provision is true, generates an SST config with an sst.aws.Redis component and runs bunx sst deploy. Outputs (host, port) are parsed from SST stdout and stored in the registry. When provision is false, the config.connection map is returned as-is.

function createRedisProvisioner(): ResourceProvisioner

Source: packages/slingshot-infra/src/resource/provisioners/redis.ts

Dispatch to the correct registry provider factory based on RegistryConfig.provider.

This is the primary factory used by the CLI and deploy pipeline to instantiate whichever registry provider is declared in slingshot.platform.ts.

function createRegistryFromConfig(config: RegistryConfig): RegistryProvider

Source: packages/slingshot-infra/src/registry/createRegistryFromConfig.ts

Configuration for the S3-backed registry provider.

function createS3Registry(config: S3RegistryConfig): RegistryProvider

Source: packages/slingshot-infra/src/registry/s3Registry.ts

Result of a secrets presence check.

function createSecretsManager(config: PlatformSecretsConfig, stageName: string,): SecretsManager

Source: packages/slingshot-infra/src/secrets/secretsManager.ts

Apply a user override to a generated deployment file.

Override dispatch rules:

  • undefined → return generated unchanged.
  • string → replace file content entirely with the file at that path.
  • object + .json file → deep-merge into the parsed JSON.
  • object + .yml/.yaml file → deep-merge into the parsed YAML.
  • object + any other format → replace named sections using # --- section:name --- / # --- end:name --- markers.
function deepMerge(target: Record<string, unknown>, source: Record<string, unknown>,): Record<string, unknown>

Source: packages/slingshot-infra/src/override/resolveOverrides.ts

Define and validate the infrastructure configuration for a single Slingshot app.

Validates config against the Zod schema and returns a frozen, immutable copy. Typically placed in a slingshot.infra.ts file at the app root.

function defineInfra(config: DefineInfraConfig): Readonly<DefineInfraConfig>

Source: packages/slingshot-infra/src/config/infraSchema.ts

Define and validate the platform configuration for a Slingshot organisation.

Validates config against the full Zod schema (registry provider requirements, stage declarations, DNS provider checks) and returns a frozen, immutable copy.

Typically placed in a slingshot.platform.ts file at the repository root, shared by all apps in the monorepo.

function definePlatform(config: DefinePlatformConfig): Readonly<DefinePlatformConfig>

Source: packages/slingshot-infra/src/config/platformSchema.ts

Register (or update) an app entry in the registry for cross-repo coordination.

Uses an optimistic lock to prevent concurrent writes from clobbering each other. After a successful write the app appears in listApps() and can be discovered by getAppsByStack() and getAppsByResource().

async function deregisterApp(registry: RegistryProvider, appName: string): Promise<void>

Source: packages/slingshot-infra/src/registry/appRegistry.ts

Derives the uses resource list from a runtime app config object.

This is a best-effort heuristic that inspects the shape of a createApp() / createServer() config to determine which shared infrastructure resources the application needs. It is NOT a strict contract — users can always override with an explicit uses array in slingshot.infra.ts.

Usage in slingshot.infra.ts:

import { defineInfra, deriveUsesFromAppConfig } from '@lastshotlabs/slingshot-infra';
import appConfig from './src/appConfig';
export default defineInfra({
stacks: ['main'],
uses: deriveUsesFromAppConfig(appConfig),
});
function deriveUsesFromAppConfig(appConfig: Record<string, unknown>): string[]

Source: packages/slingshot-infra/src/config/deriveUsesFromApp.ts

Parameters for destroyResources().

async function destroyResources(params: DestroyResourcesParams,): Promise<DestroyResourceResult[]>

Source: packages/slingshot-infra/src/resource/destroyResources.ts

Signature for the process runner used by provisionViaSst() and destroyViaSst(). Matches the spawnSync signature to allow test overrides without spawning real child processes.

function destroyViaSst(opts: SSTDestroyOptions): Promise<void>

Source: packages/slingshot-infra/src/resource/provisionViaSst.ts

Format a DeployPlan as a human-readable text table for CLI output.

Each service entry is prefixed with + (add), ~ (update), or = (unchanged). Changes are listed on indented sub-lines. The summary line appears at the bottom.

function formatDeployPlan(plan: DeployPlan): string

Source: packages/slingshot-infra/src/deploy/formatPlan.ts

Generate a complete slingshot.infra.ts scaffold with sensible defaults.

Produces a ready-to-edit TypeScript source string that can be written to disk by the slingshot infra init CLI command.

function generateInfraTemplate(opts?: { stacks?: string[]; port?: number }): string

Source: packages/slingshot-infra/src/scaffold/infraTemplate.ts

Generate a complete slingshot.platform.ts scaffold with sensible defaults.

Produces a ready-to-edit TypeScript source string that can be written to disk by the slingshot platform init CLI command.

function generatePlatformTemplate(opts?: { org?: string; region?: string; preset?: string; stages?: string[]; resources?: string[]; }): string

Source: packages/slingshot-infra/src/scaffold/platformTemplate.ts

Generates SST config content for provisioning shared AWS resources.

Each resource type maps to Pulumi AWS providers (since SST v3 is built on Pulumi), giving fine-grained control over resource configuration.

function generateResourceSstConfig(resources: ResourceProvisionEntry[], opts: GenerateResourceSstOptions,): string

Source: packages/slingshot-infra/src/resource/generateResourceSst.ts

Register (or update) an app entry in the registry for cross-repo coordination.

Uses an optimistic lock to prevent concurrent writes from clobbering each other. After a successful write the app appears in listApps() and can be discovered by getAppsByStack() and getAppsByResource().

async function getAppsByResource(registry: RegistryProvider, resourceName: string,): Promise<RegistryAppEntry[]>

Source: packages/slingshot-infra/src/registry/appRegistry.ts

Register (or update) an app entry in the registry for cross-repo coordination.

Uses an optimistic lock to prevent concurrent writes from clobbering each other. After a successful write the app appears in listApps() and can be discovered by getAppsByStack() and getAppsByResource().

async function getAppsByStack(registry: RegistryProvider, stackName: string,): Promise<RegistryAppEntry[]>

Source: packages/slingshot-infra/src/registry/appRegistry.ts

A sibling service entry — a deployed service from another repo on the same stack.

Used by the EC2/nginx preset to generate composite docker-compose and Caddyfile configs that include all services on the stack, not just the current app’s services.

function getServiceEnv(ctx: PresetContext, serviceName: string): Record<string, string>

Source: packages/slingshot-infra/src/types/preset.ts

Register (or update) an app entry in the registry for cross-repo coordination.

Uses an optimistic lock to prevent concurrent writes from clobbering each other. After a successful write the app appears in listApps() and can be discovered by getAppsByStack() and getAppsByResource().

async function listApps(registry: RegistryProvider): Promise<RegistryAppEntry[]>

Source: packages/slingshot-infra/src/registry/appRegistry.ts

Load and return the infra config from a slingshot.infra.{ts,js,mts,mjs} file in the specified directory.

Unlike loadPlatformConfig(), the search does not traverse upward — the config file must exist in dir.

TypeScript config files require the Bun runtime.

async function loadInfraConfig(dir?: string): Promise<

Source: packages/slingshot-infra/src/loader/loadInfraConfig.ts

Load and return the platform config by searching the filesystem for a slingshot.platform.{ts,js,mts,mjs} file.

Search strategy:

  1. If the SLINGSHOT_PLATFORM environment variable is set, it is used as the absolute path to the config file.
  2. Otherwise, traverses upward from startDir (default: process.cwd()) until a config file is found or the filesystem root is reached.

TypeScript config files (.ts, .mts) require the Bun runtime — an error is thrown when loading them under Node.js.

async function loadPlatformConfig(startDir?: string): Promise<

Source: packages/slingshot-infra/src/loader/loadPlatformConfig.ts

Parse a SLINGSHOT_REGISTRY URL string into a RegistryConfig.

Supported URL schemes:

  • s3://<bucket>{ provider: 's3', bucket }
  • redis://<host>:<port> or rediss://...{ provider: 'redis', url }
  • postgres://... or postgresql://...{ provider: 'postgres', connectionString }
  • Any other string (filesystem path) → { provider: 'local', path }
function parseRegistryUrl(url: string): RegistryConfig

Source: packages/slingshot-infra/src/registry/parseRegistryUrl.ts

Signature for the process runner used by provisionViaSst() and destroyViaSst(). Matches the spawnSync signature to allow test overrides without spawning real child processes.

function provisionViaSst(opts: SSTProvisionOptions): Promise<SSTProvisionResult>

Source: packages/slingshot-infra/src/resource/provisionViaSst.ts

Register (or update) an app entry in the registry for cross-repo coordination.

Uses an optimistic lock to prevent concurrent writes from clobbering each other. After a successful write the app appears in listApps() and can be discovered by getAppsByStack() and getAppsByResource().

async function registerApp(registry: RegistryProvider, app: { name: string; repo: string; stacks: string[]; uses: string[] },): Promise<void>

Source: packages/slingshot-infra/src/registry/appRegistry.ts

Resolve the environment variable map for a service at deploy time.

Merges env sources in priority order (later sources override earlier ones):

  1. Platform stage env (platform.stages[stageName].env).
  2. Resource outputs auto-wired for resources listed in service.uses or infra.uses.
  3. App-level env from infra.env.
  4. Service-level env from service.env (highest priority).
function resolveEnvironment(platform: DefinePlatformConfig, infra: DefineInfraConfig, stageName: string, registry: RegistryDocument, service?: ServiceDeclaration,): Record<string, string>

Source: packages/slingshot-infra/src/deploy/resolveEnv.ts

Apply a user override to a generated deployment file.

Override dispatch rules:

  • undefined → return generated unchanged.
  • string → replace file content entirely with the file at that path.
  • object + .json file → deep-merge into the parsed JSON.
  • object + .yml/.yaml file → deep-merge into the parsed YAML.
  • object + any other format → replace named sections using # --- section:name --- / # --- end:name --- markers.
async function resolveOverride(generated: GeneratedFile, override: OverrideSpec | undefined, appRoot: string,): Promise<GeneratedFile>

Source: packages/slingshot-infra/src/override/resolveOverrides.ts

Resolve multi-platform targeting by merging a named platform entry into the top-level platform config.

When targetPlatform is supplied, the matching entry under rawConfig.platforms[targetPlatform] is merged over the top-level fields (provider, region, registry, secrets, resources, stacks, stages, defaults). This allows a single slingshot.platform.ts to describe multiple deployment targets (e.g. different AWS accounts or regions for different clients).

function resolvePlatformConfig(rawConfig: DefinePlatformConfig, targetPlatform?: string,): DefinePlatformConfig

Source: packages/slingshot-infra/src/config/resolvePlatformConfig.ts

Resolve the required secret/env var keys for an app based on its resource usage.

Collects all unique resources from infra.uses and each service’s uses array, looks them up in RESOURCE_ENV_KEYS, and appends the always-required baseline keys (JWT_SECRET, DATA_ENCRYPTION_KEY).

function resolveRequiredKeys(infra: { uses?: string[]; services?: Record<string, { uses?: string[] }>; }): string[]

Source: packages/slingshot-infra/src/secrets/resolveRequiredKeys.ts

Options for runDeployPipeline().

async function runDeployPipeline(opts: DeployPipelineOptions,): Promise<DeployPipelineResult>

Source: packages/slingshot-infra/src/deploy/pipeline.ts

Options for runRollback().

async function runRollback(opts: RollbackOptions): Promise<RollbackResult>

Source: packages/slingshot-infra/src/deploy/rollback.ts

Context object passed to ResourceProvisioner.provision() and destroy().

Provides all the data a provisioner needs to create or tear down AWS resources for a specific resource/stage combination.

Source: packages/slingshot-infra/src/types/resource.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

Options for runDeployPipeline().

Source: packages/slingshot-infra/src/deploy/pipeline.ts

Options for runDeployPipeline().

Source: packages/slingshot-infra/src/deploy/pipeline.ts

A computed deploy plan describing what runDeployPipeline() would change.

Source: packages/slingshot-infra/src/deploy/plan.ts

A computed deploy plan describing what runDeployPipeline() would change.

Source: packages/slingshot-infra/src/deploy/plan.ts

A sibling service entry — a deployed service from another repo on the same stack.

Used by the EC2/nginx preset to generate composite docker-compose and Caddyfile configs that include all services on the stack, not just the current app’s services.

Source: packages/slingshot-infra/src/types/preset.ts

Parameters for destroyResources().

Source: packages/slingshot-infra/src/resource/destroyResources.ts

Parameters for destroyResources().

Source: packages/slingshot-infra/src/resource/destroyResources.ts

A single DNS record returned by the Cloudflare API.

Source: packages/slingshot-infra/src/dns/cloudflare.ts

High-level DNS management interface used by the deploy pipeline.

Implementations are created by createDnsManager() based on the DnsProviderConfig.provider field: 'cloudflare' is fully implemented, 'manual' logs instructions without making API calls, and 'route53' throws on every method until implemented.

Source: packages/slingshot-infra/src/dns/manager.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

A single DNS record returned by the Cloudflare API.

Source: packages/slingshot-infra/src/dns/cloudflare.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

Configuration options for the EC2/nginx (or Caddy) preset.

Source: packages/slingshot-infra/src/preset/ec2-nginx/ec2NginxPreset.ts

Configuration options for the ECS preset.

Source: packages/slingshot-infra/src/preset/ecs/ecsPreset.ts

A sibling service entry — a deployed service from another repo on the same stack.

Used by the EC2/nginx preset to generate composite docker-compose and Caddyfile configs that include all services on the stack, not just the current app’s services.

Source: packages/slingshot-infra/src/types/preset.ts

Generates SST config content for provisioning shared AWS resources.

Each resource type maps to Pulumi AWS providers (since SST v3 is built on Pulumi), giving fine-grained control over resource configuration.

Source: packages/slingshot-infra/src/resource/generateResourceSst.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

Derives the uses resource list from a runtime app config object.

This is a best-effort heuristic that inspects the shape of a createApp() / createServer() config to determine which shared infrastructure resources the application needs. It is NOT a strict contract — users can always override with an explicit uses array in slingshot.infra.ts.

Usage in slingshot.infra.ts:

import { defineInfra, deriveUsesFromAppConfig } from '@lastshotlabs/slingshot-infra';
import appConfig from './src/appConfig';
export default defineInfra({
stacks: ['main'],
uses: deriveUsesFromAppConfig(appConfig),
});

Source: packages/slingshot-infra/src/config/deriveUsesFromApp.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

Configuration for the local filesystem registry provider.

Source: packages/slingshot-infra/src/registry/localRegistry.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

Override spec for a single generated deployment file.

  • string: path to a file that replaces the generated one entirely. Absolute paths are used as-is; relative paths are resolved from app root.

  • object: deep-merged into the generated configuration. For structured formats (JSON, YAML), the object is parsed, merged, and re-serialized. For text formats (Dockerfile, NGINX/Caddy config), object keys map to named # --- section:name --- blocks in the generated template.

Source: packages/slingshot-infra/src/types/override.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

A sibling service entry — a deployed service from another repo on the same stack.

Used by the EC2/nginx preset to generate composite docker-compose and Caddyfile configs that include all services on the stack, not just the current app’s services.

Source: packages/slingshot-infra/src/types/preset.ts

A sibling service entry — a deployed service from another repo on the same stack.

Used by the EC2/nginx preset to generate composite docker-compose and Caddyfile configs that include all services on the stack, not just the current app’s services.

Source: packages/slingshot-infra/src/types/preset.ts

A sibling service entry — a deployed service from another repo on the same stack.

Used by the EC2/nginx preset to generate composite docker-compose and Caddyfile configs that include all services on the stack, not just the current app’s services.

Source: packages/slingshot-infra/src/types/preset.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

Registry entry for a deployed app (for cross-repo coordination).

Written by registerApp() and read by getAppsByStack() / getAppsByResource(). Enables platform operators to discover which repos deploy to which stacks and consume which shared resources.

Source: packages/slingshot-infra/src/types/registry.ts

Context object passed to ResourceProvisioner.provision() and destroy().

Provides all the data a provisioner needs to create or tear down AWS resources for a specific resource/stage combination.

Source: packages/slingshot-infra/src/types/resource.ts

Generates SST config content for provisioning shared AWS resources.

Each resource type maps to Pulumi AWS providers (since SST v3 is built on Pulumi), giving fine-grained control over resource configuration.

Source: packages/slingshot-infra/src/resource/generateResourceSst.ts

Context object passed to ResourceProvisioner.provision() and destroy().

Provides all the data a provisioner needs to create or tear down AWS resources for a specific resource/stage combination.

Source: packages/slingshot-infra/src/types/resource.ts

Context object passed to ResourceProvisioner.provision() and destroy().

Provides all the data a provisioner needs to create or tear down AWS resources for a specific resource/stage combination.

Source: packages/slingshot-infra/src/types/resource.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

Options for runRollback().

Source: packages/slingshot-infra/src/deploy/rollback.ts

Options for runRollback().

Source: packages/slingshot-infra/src/deploy/rollback.ts

Configuration for the S3-backed registry provider.

Source: packages/slingshot-infra/src/registry/s3Registry.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

Result of a secrets presence check.

Source: packages/slingshot-infra/src/secrets/secretsManager.ts

Result of a secrets presence check.

Source: packages/slingshot-infra/src/secrets/secretsManager.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

Signature for the process runner used by provisionViaSst() and destroyViaSst(). Matches the spawnSync signature to allow test overrides without spawning real child processes.

Source: packages/slingshot-infra/src/resource/provisionViaSst.ts

Signature for the process runner used by provisionViaSst() and destroyViaSst(). Matches the spawnSync signature to allow test overrides without spawning real child processes.

Source: packages/slingshot-infra/src/resource/provisionViaSst.ts

Signature for the process runner used by provisionViaSst() and destroyViaSst(). Matches the spawnSync signature to allow test overrides without spawning real child processes.

Source: packages/slingshot-infra/src/resource/provisionViaSst.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

DNS provider configuration for automatic domain record management.

Attached to DefinePlatformConfig.dns. The deploy pipeline calls createDnsManager(config) after a successful deploy.

Source: packages/slingshot-infra/src/types/platform.ts

WebSocket scaling diagnostics — pure helper that inspects a runtime app config and returns scaling-related warnings/infos.

Designed to be merged into the output of slingshot infra check. The function is stateless and has no side effects.

Source: packages/slingshot-infra/src/config/websocketScalingAudit.ts

WebSocket scaling diagnostics — pure helper that inspects a runtime app config and returns scaling-related warnings/infos.

Designed to be merged into the output of slingshot infra check. The function is stateless and has no side effects.

Source: packages/slingshot-infra/src/config/websocketScalingAudit.ts

The frozen, validated output of defineInfra().

Describes a single app’s deployment configuration: which stacks it targets, what resources it consumes, how its services are declared, and how generated files should be customized.

Remarks: Always obtained from defineInfra() — never constructed directly. The object is deepFreeze()d at creation time.

Source: packages/slingshot-infra/src/types/infra.ts

Override spec for a single generated deployment file.

  • string: path to a file that replaces the generated one entirely. Absolute paths are used as-is; relative paths are resolved from app root.

  • object: deep-merged into the generated configuration. For structured formats (JSON, YAML), the object is parsed, merged, and re-serialized. For text formats (Dockerfile, NGINX/Caddy config), object keys map to named # --- section:name --- blocks in the generated template.

Source: packages/slingshot-infra/src/types/override.ts

Signature for the process runner used by provisionViaSst() and destroyViaSst(). Matches the spawnSync signature to allow test overrides without spawning real child processes.

Source: packages/slingshot-infra/src/resource/provisionViaSst.ts

WebSocket scaling diagnostics — pure helper that inspects a runtime app config and returns scaling-related warnings/infos.

Designed to be merged into the output of slingshot infra check. The function is stateless and has no side effects.

Source: packages/slingshot-infra/src/config/websocketScalingAudit.ts