sst 1.16.0 → 2.0.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/{dist/app.d.ts → app.d.ts} +8 -1
- package/app.js +122 -0
- package/{dist/bootstrap.d.ts → bootstrap.d.ts} +1 -0
- package/bootstrap.js +79 -0
- package/{dist/bus.d.ts → bus.d.ts} +0 -0
- package/{dist/bus.js → bus.js} +0 -0
- package/{dist/cache.d.ts → cache.d.ts} +0 -0
- package/{dist/cache.js → cache.js} +0 -0
- package/{dist/cdk → cdk}/cloudformation-deployments.d.ts +1 -1
- package/{dist/cdk → cdk}/cloudformation-deployments.js +1 -0
- package/{dist/cdk → cdk}/deploy-stack.d.ts +0 -0
- package/{dist/cdk → cdk}/deploy-stack.js +13 -6
- package/{dist/cli → cli}/commands/bind.d.ts +3 -1
- package/{dist/cli → cli}/commands/bind.js +8 -4
- package/{dist/cli → cli}/commands/build.d.ts +2 -0
- package/cli/commands/build.js +12 -0
- package/cli/commands/console.d.ts +9 -0
- package/cli/commands/console.js +15 -0
- package/{dist/cli → cli}/commands/deploy.d.ts +7 -1
- package/cli/commands/deploy.js +48 -0
- package/cli/commands/dev.d.ts +11 -0
- package/cli/commands/dev.js +188 -0
- package/cli/commands/env.d.ts +11 -0
- package/cli/commands/env.js +39 -0
- package/cli/commands/plugins/kysely.d.ts +1 -0
- package/cli/commands/plugins/kysely.js +91 -0
- package/cli/commands/plugins/pothos.d.ts +1 -0
- package/cli/commands/plugins/pothos.js +52 -0
- package/cli/commands/plugins/warmer.d.ts +1 -0
- package/cli/commands/plugins/warmer.js +33 -0
- package/cli/commands/remove.d.ts +13 -0
- package/cli/commands/remove.js +39 -0
- package/{dist/cli → cli}/commands/secrets/get.d.ts +2 -0
- package/{dist/cli → cli}/commands/secrets/get.js +0 -0
- package/{dist/cli → cli}/commands/secrets/list.d.ts +2 -0
- package/{dist/cli → cli}/commands/secrets/list.js +5 -5
- package/{dist/cli → cli}/commands/secrets/remove.d.ts +2 -0
- package/{dist/cli → cli}/commands/secrets/remove.js +0 -0
- package/{dist/cli → cli}/commands/secrets/secrets.d.ts +0 -0
- package/{dist/cli → cli}/commands/secrets/secrets.js +0 -0
- package/{dist/cli → cli}/commands/secrets/set.d.ts +2 -0
- package/{dist/cli → cli}/commands/secrets/set.js +13 -11
- package/{dist/cli → cli}/commands/update.d.ts +2 -0
- package/{dist/cli → cli}/commands/update.js +17 -21
- package/cli/local/router.d.ts +42 -0
- package/cli/local/router.js +43 -0
- package/cli/local/server.d.ts +20 -0
- package/cli/local/server.js +212 -0
- package/cli/program.d.ts +9 -0
- package/{dist/cli → cli}/program.js +6 -1
- package/{dist/cli → cli}/spinner.d.ts +0 -0
- package/{dist/cli → cli}/spinner.js +0 -0
- package/cli/sst.d.ts +2 -0
- package/{dist/cli → cli}/sst.js +27 -16
- package/cli/telemetry/environment.d.ts +15 -0
- package/cli/telemetry/environment.js +27 -0
- package/cli/telemetry/post-payload.d.ts +1 -0
- package/cli/telemetry/post-payload.js +18 -0
- package/cli/telemetry/project-id.d.ts +2 -0
- package/cli/telemetry/project-id.js +47 -0
- package/cli/telemetry/telemetry.d.ts +4 -0
- package/cli/telemetry/telemetry.js +90 -0
- package/cli/ui/deploy.d.ts +8 -0
- package/{dist/cli → cli}/ui/deploy.js +39 -1
- package/{dist/config.d.ts → config.d.ts} +0 -0
- package/{dist/config.js → config.js} +16 -4
- package/{dist/constructs → constructs}/Api.d.ts +98 -12
- package/{dist/constructs → constructs}/Api.js +93 -7
- package/{dist/constructs → constructs}/ApiGatewayV1Api.d.ts +0 -0
- package/{dist/constructs → constructs}/ApiGatewayV1Api.js +10 -5
- package/{dist/constructs → constructs}/App.d.ts +4 -26
- package/{dist/constructs → constructs}/App.js +119 -99
- package/{dist/constructs → constructs}/AppSyncApi.d.ts +3 -3
- package/{dist/constructs → constructs}/AppSyncApi.js +27 -20
- package/constructs/AstroSite.d.ts +25 -0
- package/constructs/AstroSite.js +111 -0
- package/constructs/AstroSite.tsdoc.d.ts +2 -0
- package/constructs/AstroSite.tsdoc.js +2 -0
- package/{dist/constructs → constructs}/Auth.d.ts +1 -1
- package/{dist/constructs → constructs}/Auth.js +6 -4
- package/{dist/constructs → constructs}/BaseSite.d.ts +0 -0
- package/{dist/constructs → constructs}/BaseSite.js +0 -0
- package/{dist/constructs → constructs}/Bucket.d.ts +0 -0
- package/{dist/constructs → constructs}/Bucket.js +6 -3
- package/{dist/constructs → constructs}/Cognito.d.ts +0 -0
- package/{dist/constructs → constructs}/Cognito.js +4 -1
- package/{dist/constructs → constructs}/Config.d.ts +0 -0
- package/{dist/constructs → constructs}/Config.js +0 -0
- package/{dist/constructs → constructs}/Construct.d.ts +0 -0
- package/{dist/constructs → constructs}/Construct.js +0 -0
- package/{dist/constructs → constructs}/Cron.d.ts +0 -0
- package/{dist/constructs → constructs}/Cron.js +7 -0
- package/{dist/constructs → constructs}/DebugApp.d.ts +2 -2
- package/{dist/constructs → constructs}/DebugApp.js +16 -0
- package/{dist/constructs → constructs}/DebugStack.d.ts +0 -0
- package/{dist/constructs → constructs}/DebugStack.js +4 -0
- package/{dist/constructs → constructs}/EdgeFunction.d.ts +1 -0
- package/{dist/constructs → constructs}/EdgeFunction.js +27 -22
- package/{dist/constructs → constructs}/EventBus.d.ts +0 -0
- package/{dist/constructs → constructs}/EventBus.js +7 -4
- package/{dist/constructs → constructs}/Function.d.ts +73 -174
- package/{dist/constructs → constructs}/Function.js +43 -83
- package/{dist/constructs → constructs}/FunctionalStack.d.ts +0 -0
- package/{dist/constructs → constructs}/FunctionalStack.js +5 -5
- package/{dist/constructs → constructs}/GraphQLApi.d.ts +11 -1
- package/{dist/constructs → constructs}/GraphQLApi.js +3 -0
- package/{dist/constructs → constructs}/Job.d.ts +0 -14
- package/{dist/constructs → constructs}/Job.js +50 -46
- package/{dist/constructs → constructs}/KinesisStream.d.ts +0 -0
- package/{dist/constructs → constructs}/KinesisStream.js +6 -3
- package/{dist/constructs → constructs}/Metadata.d.ts +1 -1
- package/{dist/constructs → constructs}/Metadata.js +0 -0
- package/constructs/NextjsSite.d.ts +33 -0
- package/constructs/NextjsSite.js +285 -0
- package/{dist/constructs → constructs}/Parameter.d.ts +0 -0
- package/{dist/constructs → constructs}/Parameter.js +3 -0
- package/{dist/constructs → constructs}/Queue.d.ts +0 -0
- package/{dist/constructs → constructs}/Queue.js +19 -12
- package/{dist/constructs → constructs}/RDS.d.ts +0 -0
- package/{dist/constructs → constructs}/RDS.js +26 -19
- package/{dist/constructs → constructs}/ReactStaticSite.d.ts +0 -0
- package/{dist/constructs → constructs}/ReactStaticSite.js +1 -1
- package/constructs/RemixSite.d.ts +28 -0
- package/constructs/RemixSite.js +150 -0
- package/constructs/RemixSite.tsdoc.d.ts +2 -0
- package/constructs/RemixSite.tsdoc.js +2 -0
- package/{dist/constructs → constructs}/Script/cfn-response.d.ts +0 -0
- package/{dist/constructs → constructs}/Script/cfn-response.js +0 -0
- package/{dist/constructs → constructs}/Script/index.d.ts +0 -0
- package/{dist/constructs → constructs}/Script/index.js +0 -0
- package/{dist/constructs → constructs}/Script/outbound.d.ts +1 -1
- package/{dist/constructs → constructs}/Script/outbound.js +0 -0
- package/{dist/constructs → constructs}/Script/util.d.ts +0 -0
- package/{dist/constructs → constructs}/Script/util.js +0 -0
- package/{dist/constructs → constructs}/Script.d.ts +0 -0
- package/{dist/constructs → constructs}/Script.js +13 -0
- package/{dist/constructs → constructs}/Secret.d.ts +0 -0
- package/{dist/constructs → constructs}/Secret.js +2 -0
- package/constructs/SolidStartSite.d.ts +24 -0
- package/constructs/SolidStartSite.js +103 -0
- package/constructs/SolidStartSite.tsdoc.d.ts +2 -0
- package/constructs/SolidStartSite.tsdoc.js +2 -0
- package/{dist/constructs/RemixSite.d.ts → constructs/SsrSite.d.ts} +69 -107
- package/{dist/constructs/RemixSite.js → constructs/SsrSite.js} +243 -446
- package/{dist/constructs → constructs}/Stack.d.ts +1 -1
- package/{dist/constructs → constructs}/Stack.js +19 -4
- package/{dist/constructs → constructs}/StaticSite.d.ts +44 -17
- package/{dist/constructs → constructs}/StaticSite.js +121 -72
- package/{dist/constructs → constructs}/Table.d.ts +0 -0
- package/{dist/constructs → constructs}/Table.js +9 -3
- package/{dist/constructs → constructs}/Topic.d.ts +0 -0
- package/{dist/constructs → constructs}/Topic.js +6 -3
- package/{dist/constructs → constructs}/ViteStaticSite.d.ts +0 -0
- package/{dist/constructs → constructs}/ViteStaticSite.js +2 -2
- package/{dist/constructs → constructs}/WebSocketApi.d.ts +0 -0
- package/{dist/constructs → constructs}/WebSocketApi.js +9 -4
- package/{dist/constructs → constructs}/context.d.ts +1 -1
- package/{dist/constructs → constructs}/context.js +0 -0
- package/{dist/constructs → constructs}/deferred_task.d.ts +0 -0
- package/{dist/constructs → constructs}/deferred_task.js +4 -2
- package/{dist/constructs → constructs/deprecated}/NextjsSite.d.ts +12 -8
- package/{dist/constructs → constructs/deprecated}/NextjsSite.js +112 -89
- package/{dist/constructs/nextjs-site → constructs/deprecated}/cross-region-helper.d.ts +0 -0
- package/{dist/constructs/nextjs-site → constructs/deprecated}/cross-region-helper.js +3 -3
- package/constructs/deprecated/index.d.ts +1 -0
- package/constructs/deprecated/index.js +1 -0
- package/{dist/constructs → constructs}/index.d.ts +3 -2
- package/{dist/constructs → constructs}/index.js +2 -0
- package/{dist/constructs → constructs}/util/apiGatewayV1AccessLog.d.ts +0 -0
- package/{dist/constructs → constructs}/util/apiGatewayV1AccessLog.js +0 -0
- package/{dist/constructs → constructs}/util/apiGatewayV2AccessLog.d.ts +0 -0
- package/{dist/constructs → constructs}/util/apiGatewayV2AccessLog.js +4 -4
- package/{dist/constructs → constructs}/util/apiGatewayV2Cors.d.ts +0 -0
- package/{dist/constructs → constructs}/util/apiGatewayV2Cors.js +0 -0
- package/{dist/constructs → constructs}/util/apiGatewayV2Domain.d.ts +0 -0
- package/{dist/constructs → constructs}/util/apiGatewayV2Domain.js +0 -0
- package/{dist/constructs → constructs}/util/appSyncApiDomain.d.ts +1 -1
- package/{dist/constructs → constructs}/util/appSyncApiDomain.js +15 -9
- package/{dist/constructs → constructs}/util/builder.d.ts +0 -0
- package/{dist/constructs → constructs}/util/builder.js +0 -0
- package/{dist/constructs → constructs}/util/duration.d.ts +0 -0
- package/{dist/constructs → constructs}/util/duration.js +0 -0
- package/{dist/constructs → constructs}/util/functionBinding.d.ts +0 -0
- package/{dist/constructs → constructs}/util/functionBinding.js +0 -0
- package/{dist/constructs → constructs}/util/functionUrlCors.d.ts +0 -0
- package/{dist/constructs → constructs}/util/functionUrlCors.js +0 -0
- package/{dist/constructs → constructs}/util/permission.d.ts +0 -0
- package/{dist/constructs → constructs}/util/permission.js +32 -16
- package/{dist/constructs → constructs}/util/python/bundling.d.ts +0 -0
- package/{dist/constructs → constructs}/util/python/bundling.js +0 -0
- package/{dist/constructs → constructs}/util/size.d.ts +0 -0
- package/{dist/constructs → constructs}/util/size.js +0 -0
- package/{dist/constructs → constructs}/util/warning.d.ts +0 -0
- package/{dist/constructs → constructs}/util/warning.js +0 -0
- package/{dist/context → context}/context.d.ts +1 -1
- package/{dist/context → context}/context.js +3 -4
- package/{dist/context → context}/handler.d.ts +0 -0
- package/{dist/context → context}/handler.js +1 -1
- package/{dist/context → context}/index.d.ts +0 -0
- package/{dist/context → context}/index.js +0 -0
- package/{dist/credentials.d.ts → credentials.d.ts} +3 -1
- package/{dist/credentials.js → credentials.js} +11 -3
- package/{dist/error.d.ts → error.d.ts} +0 -0
- package/{dist/error.js → error.js} +0 -0
- package/{dist/iot.d.ts → iot.d.ts} +0 -0
- package/{dist/iot.js → iot.js} +3 -0
- package/logger.d.ts +3 -0
- package/{dist/logger.js → logger.js} +12 -8
- package/node/api/index.d.ts +42 -0
- package/node/api/index.js +88 -0
- package/node/auth/adapter/adapter.d.ts +3 -0
- package/node/auth/adapter/adapter.js +3 -0
- package/node/auth/adapter/facebook.d.ts +2 -0
- package/node/auth/adapter/facebook.js +26 -0
- package/node/auth/adapter/github.d.ts +2 -0
- package/node/auth/adapter/github.js +21 -0
- package/node/auth/adapter/google.d.ts +9 -0
- package/node/auth/adapter/google.js +18 -0
- package/node/auth/adapter/link.d.ts +8 -0
- package/node/auth/adapter/link.js +39 -0
- package/node/auth/adapter/oauth.d.ts +25 -0
- package/node/auth/adapter/oauth.js +52 -0
- package/node/auth/adapter/oidc.d.ts +17 -0
- package/node/auth/adapter/oidc.js +50 -0
- package/node/auth/adapter/twitch.d.ts +2 -0
- package/node/auth/adapter/twitch.js +11 -0
- package/node/auth/auth.d.ts +24 -0
- package/node/auth/auth.js +118 -0
- package/node/auth/index.d.ts +10 -0
- package/node/auth/index.js +10 -0
- package/node/auth/session.d.ts +76 -0
- package/node/auth/session.js +109 -0
- package/node/bucket/index.d.ts +3 -0
- package/node/bucket/index.js +3 -0
- package/node/config/index.d.ts +13 -0
- package/node/config/index.js +88 -0
- package/node/event-bus/index.d.ts +3 -0
- package/node/event-bus/index.js +3 -0
- package/node/function/index.d.ts +3 -0
- package/node/function/index.js +3 -0
- package/node/graphql/index.d.ts +38 -0
- package/node/graphql/index.js +48 -0
- package/node/job/index.d.ts +34 -0
- package/node/job/index.js +51 -0
- package/node/kinesis-stream/index.d.ts +3 -0
- package/node/kinesis-stream/index.js +3 -0
- package/node/queue/index.d.ts +3 -0
- package/node/queue/index.js +3 -0
- package/node/rds/index.d.ts +3 -0
- package/node/rds/index.js +3 -0
- package/node/site/index.d.ts +15 -0
- package/node/site/index.js +64 -0
- package/node/table/index.d.ts +3 -0
- package/node/table/index.js +3 -0
- package/node/topic/index.d.ts +3 -0
- package/node/topic/index.js +3 -0
- package/node/util/index.d.ts +7 -0
- package/node/util/index.js +57 -0
- package/package.json +107 -40
- package/pothos.d.ts +8 -0
- package/pothos.js +156 -0
- package/runtime/handlers/dotnet.d.ts +1 -0
- package/runtime/handlers/dotnet.js +117 -0
- package/runtime/handlers/go.d.ts +1 -0
- package/runtime/handlers/go.js +105 -0
- package/runtime/handlers/java.d.ts +1 -0
- package/runtime/handlers/java.js +97 -0
- package/{dist/runtime → runtime/handlers}/node.d.ts +0 -0
- package/runtime/handlers/node.js +172 -0
- package/runtime/handlers/python.d.ts +1 -0
- package/runtime/handlers/python.js +89 -0
- package/{dist/runtime → runtime}/handlers.d.ts +30 -12
- package/runtime/handlers.js +117 -0
- package/{dist/runtime → runtime}/iot.d.ts +0 -0
- package/{dist/runtime → runtime}/iot.js +1 -1
- package/{dist/runtime → runtime}/runtime.d.ts +2 -0
- package/{dist/runtime → runtime}/runtime.js +0 -0
- package/{dist/runtime → runtime}/server.d.ts +0 -0
- package/{dist/runtime → runtime}/server.js +39 -3
- package/{dist/runtime → runtime}/workers.d.ts +1 -0
- package/{dist/runtime → runtime}/workers.js +12 -4
- package/{dist/cli/sst.d.ts → scrap.d.ts} +0 -0
- package/scrap.js +58 -0
- package/site-env.d.ts +13 -0
- package/site-env.js +47 -0
- package/sst.mjs +21848 -0
- package/{dist/stacks → stacks}/build.d.ts +0 -0
- package/{dist/stacks → stacks}/build.js +18 -9
- package/stacks/deploy.d.ts +8 -0
- package/stacks/deploy.js +105 -0
- package/stacks/index.d.ts +7 -0
- package/stacks/index.js +7 -0
- package/stacks/metadata.d.ts +9 -0
- package/{dist/stacks → stacks}/metadata.js +2 -14
- package/stacks/monitor.d.ts +27 -0
- package/stacks/monitor.js +111 -0
- package/stacks/remove.d.ts +8 -0
- package/stacks/remove.js +80 -0
- package/stacks/synth.d.ts +10 -0
- package/stacks/synth.js +77 -0
- package/support/astro-site-html-stub/index.html +99 -0
- package/support/base-site-archiver.cjs +12 -11
- package/support/base-site-archiver.mjs +20 -0
- package/support/bridge/bridge.mjs +59 -0
- package/{dist/support → support}/custom-resources/index.mjs +44209 -42781
- package/support/dotnet31-bootstrap/Program.cs +17 -0
- package/support/dotnet31-bootstrap/dotnet-bootstrap.csproj +12 -0
- package/support/dotnet31-bootstrap/release/Amazon.Lambda.Core.dll +0 -0
- package/support/dotnet31-bootstrap/release/Amazon.Lambda.RuntimeSupport.dll +0 -0
- package/support/dotnet31-bootstrap/release/System.Runtime.CompilerServices.Unsafe.dll +0 -0
- package/support/dotnet31-bootstrap/release/System.Text.Encodings.Web.dll +0 -0
- package/support/dotnet31-bootstrap/release/System.Text.Json.dll +0 -0
- package/support/dotnet31-bootstrap/release/dotnet-bootstrap +0 -0
- package/support/dotnet31-bootstrap/release/dotnet-bootstrap.deps.json +230 -0
- package/support/dotnet31-bootstrap/release/dotnet-bootstrap.dll +0 -0
- package/support/dotnet31-bootstrap/release/dotnet-bootstrap.pdb +0 -0
- package/support/dotnet31-bootstrap/release/dotnet-bootstrap.runtimeconfig.json +9 -0
- package/support/dotnet6-bootstrap/Program.cs +17 -0
- package/support/dotnet6-bootstrap/dotnet-bootstrap.csproj +12 -0
- package/support/dotnet6-bootstrap/release/Amazon.Lambda.Core.dll +0 -0
- package/support/dotnet6-bootstrap/release/Amazon.Lambda.RuntimeSupport.dll +0 -0
- package/support/dotnet6-bootstrap/release/dotnet-bootstrap +0 -0
- package/support/dotnet6-bootstrap/release/dotnet-bootstrap.deps.json +59 -0
- package/support/dotnet6-bootstrap/release/dotnet-bootstrap.dll +0 -0
- package/support/dotnet6-bootstrap/release/dotnet-bootstrap.pdb +0 -0
- package/support/dotnet6-bootstrap/release/dotnet-bootstrap.runtimeconfig.json +12 -0
- package/support/edge-function/edge-lambda-version.mjs +3 -0
- package/support/edge-function/edge-lambda.mjs +3 -0
- package/support/edge-function/s3-bucket.mjs +3 -0
- package/{dist/support/base-site-custom-resource/cf-invalidate.py → support/edge-function-code-replacer/lambda-code-updater.py} +56 -30
- package/support/java-runtime/install.sh +25 -0
- package/support/java-runtime/pom.xml +39 -0
- package/support/java-runtime/release/aws-lambda-java-core-1.2.0.jar +0 -0
- package/support/java-runtime/release/aws-lambda-java-runtime-interface-client-1.1.0.jar +0 -0
- package/support/java-runtime/release/aws-lambda-java-serialization-1.0.0.jar +0 -0
- package/support/nextjs-site-html-stub/index.html +99 -0
- package/{dist/support → support}/nodejs-runtime/index.mjs +7822 -2771
- package/support/python-runtime/runtime.py +116 -0
- package/support/rds-migrator/index.mjs +28 -0
- package/support/remix-site-function/edge-server.js +158 -0
- package/support/remix-site-function/polyfill.js +24 -0
- package/support/remix-site-function/regional-server.js +162 -0
- package/support/remix-site-html-stub/index.html +99 -0
- package/support/sls-nextjs-site-build-helper/build.cjs +91 -0
- package/support/sls-nextjs-site-build-helper/index-wrapper.js +19 -0
- package/support/sls-nextjs-site-stub/index.html +99 -0
- package/support/solid-start-site-html-stub/index.html +99 -0
- package/support/ssr-site-function-stub/index.js +5 -0
- package/util/fs.d.ts +4 -0
- package/util/fs.js +46 -0
- package/util/module.d.ts +1 -0
- package/util/module.js +5 -0
- package/util/process.d.ts +2 -0
- package/util/process.js +3 -0
- package/{dist/watcher.d.ts → watcher.d.ts} +0 -0
- package/{dist/watcher.js → watcher.js} +1 -1
- package/.build/sst-debug.log +0 -10
- package/.turbo/turbo-build.log +0 -2
- package/CHANGELOG.md +0 -332
- package/analyze +0 -11090
- package/bin/sst.mjs +0 -3
- package/build.mjs +0 -116
- package/debug.log +0 -6
- package/dist/app.js +0 -92
- package/dist/bootstrap.js +0 -23
- package/dist/cli/commands/build.js +0 -8
- package/dist/cli/commands/deploy.js +0 -20
- package/dist/cli/commands/env.d.ts +0 -0
- package/dist/cli/commands/env.js +0 -1
- package/dist/cli/commands/scrap.d.ts +0 -5
- package/dist/cli/commands/scrap.js +0 -1
- package/dist/cli/commands/start.d.ts +0 -7
- package/dist/cli/commands/start.js +0 -136
- package/dist/cli/program.d.ts +0 -7
- package/dist/cli/ui/deploy.d.ts +0 -6
- package/dist/constructs/nextjs-site/custom-resource/cfn-response.d.ts +0 -19
- package/dist/constructs/nextjs-site/custom-resource/cfn-response.js +0 -94
- package/dist/constructs/nextjs-site/custom-resource/edge-lambda-version.d.ts +0 -1
- package/dist/constructs/nextjs-site/custom-resource/edge-lambda-version.js +0 -138
- package/dist/constructs/nextjs-site/custom-resource/edge-lambda.d.ts +0 -1
- package/dist/constructs/nextjs-site/custom-resource/edge-lambda.js +0 -136
- package/dist/constructs/nextjs-site/custom-resource/s3-bucket.d.ts +0 -1
- package/dist/constructs/nextjs-site/custom-resource/s3-bucket.js +0 -94
- package/dist/constructs/nextjs-site/custom-resource/util.d.ts +0 -1
- package/dist/constructs/nextjs-site/custom-resource/util.js +0 -4
- package/dist/logger.d.ts +0 -9
- package/dist/runtime/handlers.js +0 -72
- package/dist/runtime/node.js +0 -99
- package/dist/sst.mjs +0 -164202
- package/dist/stacks/deploy.d.ts +0 -33
- package/dist/stacks/deploy.js +0 -168
- package/dist/stacks/index.d.ts +0 -21
- package/dist/stacks/index.js +0 -57
- package/dist/stacks/metadata.d.ts +0 -9
- package/dist/support/base-site-archiver.cjs +0 -115
- package/dist/support/base-site-custom-resource/s3-handler.py +0 -195
- package/dist/support/base-site-custom-resource/s3-upload.py +0 -91
- package/dist/support/bridge/bridge.mjs +0 -86
- package/dist/support/static-site-stub/index.html +0 -90
- package/src/app.ts +0 -140
- package/src/bootstrap.ts +0 -28
- package/src/bus.ts +0 -81
- package/src/cache.ts +0 -34
- package/src/cdk/cloudformation-deployments.ts +0 -730
- package/src/cdk/deploy-stack.ts +0 -1030
- package/src/cli/commands/bind.ts +0 -31
- package/src/cli/commands/build.ts +0 -16
- package/src/cli/commands/deploy.ts +0 -34
- package/src/cli/commands/env.ts +0 -0
- package/src/cli/commands/scrap.ts +0 -5
- package/src/cli/commands/secrets/get.ts +0 -50
- package/src/cli/commands/secrets/list.ts +0 -66
- package/src/cli/commands/secrets/remove.ts +0 -36
- package/src/cli/commands/secrets/secrets.ts +0 -17
- package/src/cli/commands/secrets/set.ts +0 -59
- package/src/cli/commands/start.tsx +0 -162
- package/src/cli/commands/update.ts +0 -100
- package/src/cli/program.ts +0 -22
- package/src/cli/spinner.ts +0 -14
- package/src/cli/sst.ts +0 -50
- package/src/cli/ui/deploy.tsx +0 -139
- package/src/config.ts +0 -226
- package/src/constructs/Api.ts +0 -1448
- package/src/constructs/ApiGatewayV1Api.ts +0 -1481
- package/src/constructs/App.ts +0 -744
- package/src/constructs/AppSyncApi.ts +0 -1045
- package/src/constructs/Auth.ts +0 -252
- package/src/constructs/BaseSite.ts +0 -146
- package/src/constructs/Bucket.ts +0 -670
- package/src/constructs/Cognito.ts +0 -708
- package/src/constructs/Config.ts +0 -4
- package/src/constructs/Construct.ts +0 -77
- package/src/constructs/Cron.ts +0 -235
- package/src/constructs/DebugApp.ts +0 -97
- package/src/constructs/DebugStack.ts +0 -182
- package/src/constructs/EdgeFunction.ts +0 -460
- package/src/constructs/EventBus.ts +0 -651
- package/src/constructs/Function.ts +0 -1329
- package/src/constructs/FunctionalStack.ts +0 -90
- package/src/constructs/GraphQLApi.ts +0 -140
- package/src/constructs/Job.ts +0 -557
- package/src/constructs/KinesisStream.ts +0 -388
- package/src/constructs/Metadata.ts +0 -75
- package/src/constructs/NextjsSite.ts +0 -1498
- package/src/constructs/Parameter.ts +0 -72
- package/src/constructs/Queue.ts +0 -360
- package/src/constructs/RDS.ts +0 -578
- package/src/constructs/ReactStaticSite.ts +0 -66
- package/src/constructs/RemixSite.ts +0 -1397
- package/src/constructs/Script/cfn-response.ts +0 -116
- package/src/constructs/Script/index.ts +0 -103
- package/src/constructs/Script/outbound.ts +0 -59
- package/src/constructs/Script/package.json +0 -3
- package/src/constructs/Script/util.ts +0 -19
- package/src/constructs/Script.ts +0 -270
- package/src/constructs/Secret.ts +0 -66
- package/src/constructs/Stack.ts +0 -319
- package/src/constructs/StaticSite.ts +0 -995
- package/src/constructs/Table.ts +0 -844
- package/src/constructs/Topic.ts +0 -486
- package/src/constructs/ViteStaticSite.ts +0 -99
- package/src/constructs/WebSocketApi.ts +0 -687
- package/src/constructs/context.ts +0 -12
- package/src/constructs/deferred_task.ts +0 -53
- package/src/constructs/descs.d.ts +0 -1
- package/src/constructs/index.ts +0 -39
- package/src/constructs/nextjs-site/cross-region-helper.ts +0 -189
- package/src/constructs/nextjs-site/custom-resource/cfn-response.ts +0 -146
- package/src/constructs/nextjs-site/custom-resource/edge-lambda-version.ts +0 -162
- package/src/constructs/nextjs-site/custom-resource/edge-lambda.ts +0 -167
- package/src/constructs/nextjs-site/custom-resource/s3-bucket.ts +0 -112
- package/src/constructs/nextjs-site/custom-resource/util.ts +0 -11
- package/src/constructs/util/apiGatewayV1AccessLog.ts +0 -106
- package/src/constructs/util/apiGatewayV2AccessLog.ts +0 -139
- package/src/constructs/util/apiGatewayV2Cors.ts +0 -94
- package/src/constructs/util/apiGatewayV2Domain.ts +0 -312
- package/src/constructs/util/appSyncApiDomain.ts +0 -204
- package/src/constructs/util/builder.ts +0 -17
- package/src/constructs/util/duration.ts +0 -27
- package/src/constructs/util/functionBinding.ts +0 -102
- package/src/constructs/util/functionUrlCors.ts +0 -96
- package/src/constructs/util/permission.ts +0 -299
- package/src/constructs/util/python/bundling.ts +0 -174
- package/src/constructs/util/size.ts +0 -13
- package/src/constructs/util/warning.ts +0 -20
- package/src/context/context.ts +0 -79
- package/src/context/handler.ts +0 -53
- package/src/context/index.ts +0 -2
- package/src/credentials.ts +0 -103
- package/src/error.ts +0 -5
- package/src/iot.ts +0 -105
- package/src/logger.ts +0 -35
- package/src/runtime/handlers.ts +0 -121
- package/src/runtime/iot.ts +0 -16
- package/src/runtime/node.ts +0 -111
- package/src/runtime/runtime.ts +0 -27
- package/src/runtime/server.ts +0 -149
- package/src/runtime/workers.ts +0 -96
- package/src/stacks/build.ts +0 -69
- package/src/stacks/deploy.ts +0 -232
- package/src/stacks/index.ts +0 -73
- package/src/stacks/metadata.ts +0 -125
- package/src/watcher.ts +0 -47
- package/sst.config.mjs +0 -6
- package/support/bridge/bridge.ts +0 -136
- package/support/bridge/build.mjs +0 -18
- package/support/custom-resources/auth-keys.ts +0 -113
- package/support/custom-resources/build.mjs +0 -18
- package/support/custom-resources/cfn-response.ts +0 -151
- package/support/custom-resources/index.ts +0 -18
- package/support/custom-resources/secrets-migration.ts +0 -82
- package/support/custom-resources/stack-metadata.ts +0 -75
- package/support/custom-resources/util.ts +0 -44
- package/support/nodejs-runtime/index.ts +0 -69
- package/support/tsconfig.json +0 -11
- package/tsconfig.json +0 -13
- package/yarn-error.log +0 -75
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
|
|
4
|
-
<head>
|
|
5
|
-
<meta charset="utf-8" />
|
|
6
|
-
|
|
7
|
-
<title>SST StaticSite</title>
|
|
8
|
-
<meta name="description" content="A placeholder website deployed by SST" />
|
|
9
|
-
<meta name="author" content="SST" />
|
|
10
|
-
|
|
11
|
-
<style>
|
|
12
|
-
body,
|
|
13
|
-
html {
|
|
14
|
-
margin: 0;
|
|
15
|
-
height: 100%;
|
|
16
|
-
display: grid;
|
|
17
|
-
color: #fffbf9;
|
|
18
|
-
font-family: monospace;
|
|
19
|
-
background-color: #2e4a56;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
section {
|
|
23
|
-
margin: auto;
|
|
24
|
-
text-align: center;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
svg {
|
|
28
|
-
width: 30%;
|
|
29
|
-
height: auto;
|
|
30
|
-
margin-bottom: 30px;
|
|
31
|
-
filter: drop-shadow(0px 10px 5px rgba(0, 0, 0, 0.15));
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
p {
|
|
35
|
-
font-size: 24px;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
a {
|
|
39
|
-
color: #e27152;
|
|
40
|
-
}
|
|
41
|
-
</style>
|
|
42
|
-
</head>
|
|
43
|
-
|
|
44
|
-
<body>
|
|
45
|
-
<section>
|
|
46
|
-
<svg width="256" height="75" viewBox="0 0 256 75" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
47
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
48
|
-
d="M218.399 20.7061C218.399 20.7061 226.244 3.70391 226.488 3.33275C227.07 2.43536 227.99 1.51254 229.714 0.866821C231 0.388885 233.075 0 236.448 0C240.493 0 242.852 0.597343 244.22 1.26086C247.222 2.71499 247.774 4.78946 247.781 6.62492L247.784 8.44769L248.788 8.43241C250.346 8.43241 251.622 8.69682 252.705 9.56371C253.41 10.1281 254.154 10.9924 254.615 12.6016C254.902 13.6159 255.12 15.248 255.12 17.8792C255.12 20.4646 254.902 22.1348 254.604 23.2229C254.47 23.716 254.312 24.1406 254.137 24.5118C254.119 24.8652 254.009 25.216 253.804 25.5312L247.794 34.6703V39.9759C249.299 39.9886 250.537 40.2606 251.592 41.1072C252.299 41.6715 253.044 42.5359 253.501 44.1451C253.791 45.162 254.01 46.7915 254.01 49.4227C254.01 52.5928 253.659 54.441 253.244 55.5366C252.815 56.6679 243.808 71.7024 243.617 71.8651C243.617 71.8651 241.032 74.0438 237.762 74.0438H225.357C223.569 74.0438 221.375 73.4591 219.883 71.8092C218.892 70.711 218.162 69.1323 218.162 66.8494V21.6594C218.162 21.3264 218.244 21.001 218.399 20.7061Z"
|
|
49
|
-
fill="#395C6B" />
|
|
50
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
51
|
-
d="M164.24 28.2106C165.653 29.7334 166.528 31.818 166.528 34.5407C166.528 37.271 166.347 48.1262 166.258 53.3376C166.228 55.1833 165.653 56.978 164.603 58.4957C161.672 62.7717 155.744 72.0075 155.721 72.0405C155.721 72.0405 154.638 74.0972 148.755 74.0972H109.816C107.752 74.0972 106.102 73.3803 104.948 72.2083C103.807 71.0491 103.12 69.4043 103.12 67.3858C103.12 59.9448 103.12 35.7228 103.12 35.7685C103.12 35.7685 103.128 33.534 104.526 31.2663C105.721 29.3266 114.997 13.26 115.717 12.1999C117.173 10.0568 120.697 8.93318 123.826 8.93318C126.956 8.93318 148.923 9.03745 153.779 9.03745C158.825 9.03745 161.764 10.6975 163.576 12.622C166.312 15.5277 166.528 19.4884 166.528 21.4916C166.528 23.4237 166.36 25.4397 165.274 27.0285C164.997 27.4327 164.662 27.8344 164.24 28.2106Z"
|
|
52
|
-
fill="#395C6B" />
|
|
53
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
54
|
-
d="M218.782 28.2106C220.196 29.7334 221.07 31.818 221.07 34.5407C221.07 37.271 220.89 48.1262 220.801 53.3376C220.77 55.1833 220.196 56.978 219.146 58.4957C216.215 62.7717 210.286 72.0075 210.264 72.0405C210.264 72.0405 209.181 74.0972 203.298 74.0972H164.359C162.295 74.0972 160.645 73.3803 159.491 72.2083C158.349 71.0491 157.663 69.4043 157.663 67.3858C157.663 59.9448 157.663 35.7228 157.663 35.7685C157.663 35.7685 157.671 33.534 159.069 31.2663C160.264 29.3266 169.54 13.26 170.26 12.1999C171.716 10.0568 175.24 8.93318 178.369 8.93318C181.499 8.93318 203.466 9.03745 208.321 9.03745C213.367 9.03745 216.306 10.6975 218.119 12.622C220.854 15.5277 221.07 19.4884 221.07 21.4916C221.07 23.4237 220.903 25.4397 219.817 27.0285C219.54 27.4327 219.204 27.8344 218.782 28.2106Z"
|
|
55
|
-
fill="#395C6B" />
|
|
56
|
-
<path
|
|
57
|
-
d="M230.525 12.4008L230.446 6.65543C230.446 5.23688 230.542 3.88957 236.926 3.88957C243.22 3.88957 243.841 5.30045 243.846 6.60205L243.858 12.4008L248.78 12.3194C250.199 12.3194 251.188 12.0271 251.188 17.841C251.188 23.05 250.321 23.678 249.187 23.7542V23.7593H243.858V41.5953C243.858 43.924 245.18 43.9392 245.18 43.9392L247.667 43.863C249.088 43.863 250.077 43.5705 250.077 49.3871C250.077 55.2011 248.994 55.3079 247.667 55.3079C247.667 55.3079 236.316 55.3079 233.814 55.3079C230.123 55.3079 230.525 52.5318 230.525 50.8464V23.7593L228.618 23.767C227.199 23.767 226.211 24.0593 226.211 18.2428C226.211 12.4288 227.291 12.322 228.618 12.322L230.525 12.4008Z"
|
|
58
|
-
fill="#FFFBF9" />
|
|
59
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
60
|
-
d="M149.96 40.0268C149.96 39.7472 149.851 39.4827 149.652 39.2844C149.457 39.0887 149.19 38.9794 148.913 38.9794C144.123 38.9921 124.574 39.0404 124.574 39.0404C120.918 39.0404 117.163 37.2405 117.163 33.6027C117.163 32.3672 117.067 21.4739 117.067 21.0951C117.067 15.0345 120.623 12.5 124.68 12.5H154.526C163.368 12.5 163.35 20.2181 163.35 22.5493C163.35 24.0619 163.642 26.0956 157.828 26.0956C152.012 26.0956 151.424 25.2261 151.424 24.5372C151.424 23.8483 150.962 23.4644 150.484 23.4644C150.006 23.4644 135.932 23.4847 131.486 23.4847C131.155 23.4847 130.84 23.6144 130.606 23.8483C130.375 24.0796 130.243 24.3948 130.243 24.7253C130.243 25.371 130.243 26.6473 130.243 27.293C130.243 27.6209 130.375 27.9361 130.606 28.17C130.84 28.4039 131.155 28.5336 131.486 28.5336C136.797 28.5336 157.348 28.5336 157.348 28.5336C161.003 28.5336 163.35 30.3308 163.35 33.9713V50.4142C163.35 53.6453 160.846 55.557 156.788 55.557H125.319C119.398 55.557 117.163 52.092 117.163 47.7627V44.0536C117.163 43.2604 117.847 41.4987 123.664 41.4987C129.478 41.4987 129.752 42.2868 130.073 42.9249C130.388 43.5579 130.881 44.0536 131.486 44.0536C132.088 44.0536 144.815 44.0587 148.913 44.0612C149.192 44.0612 149.457 43.9494 149.655 43.7537C149.851 43.5579 149.96 43.291 149.96 43.0139C149.96 42.1393 149.96 40.9013 149.96 40.0268Z"
|
|
61
|
-
fill="#FFFBF9" />
|
|
62
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
63
|
-
d="M204.503 40.0268C204.503 39.7472 204.394 39.4827 204.195 39.2844C203.999 39.0887 203.732 38.9794 203.455 38.9794C198.666 38.9921 179.117 39.0404 179.117 39.0404C175.461 39.0404 171.706 37.2405 171.706 33.6027C171.706 32.3672 171.609 21.4739 171.609 21.0951C171.609 15.0345 175.166 12.5 179.223 12.5H209.069C217.91 12.5 217.893 20.2181 217.893 22.5493C217.893 24.0619 218.185 26.0956 212.371 26.0956C206.554 26.0956 205.967 25.2261 205.967 24.5372C205.967 23.8483 205.505 23.4644 205.027 23.4644C204.549 23.4644 190.475 23.4847 186.026 23.4847C185.698 23.4847 185.383 23.6144 185.149 23.8483C184.918 24.0796 184.786 24.3948 184.786 24.7253C184.786 25.371 184.786 26.6473 184.786 27.293C184.786 27.6209 184.918 27.9361 185.149 28.17C185.383 28.4039 185.698 28.5336 186.026 28.5336C191.339 28.5336 211.89 28.5336 211.89 28.5336C215.546 28.5336 217.893 30.3308 217.893 33.9713V50.4142C217.893 53.6453 215.389 55.557 211.331 55.557H179.861C173.941 55.557 171.706 52.092 171.706 47.7627V44.0536C171.706 43.2604 172.39 41.4987 178.206 41.4987C184.02 41.4987 184.295 42.2868 184.615 42.9249C184.931 43.5579 185.424 44.0536 186.026 44.0536C186.631 44.0536 199.357 44.0587 203.455 44.0612C203.735 44.0612 203.999 43.9494 204.198 43.7537C204.393 43.5579 204.503 43.291 204.503 43.0139C204.503 42.1393 204.503 40.9013 204.503 40.0268Z"
|
|
64
|
-
fill="#FFFBF9" />
|
|
65
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
66
|
-
d="M22.3366 60.4998C22.3963 60.4118 22.4025 60.2981 22.3527 60.2034C22.3029 60.11 22.2052 60.0518 22.0988 60.0518C19.8457 60.0518 11.0675 60.0518 5.27476 60.0518C3.87494 60.0518 2.53263 59.4956 1.54343 58.5049C0.554086 57.5142 -0.00121606 56.1716 1.99966e-06 54.7722C0.00595698 47.4814 0.0165138 34.7255 0.020168 30.2823C0.0209801 29.247 0.292474 28.2306 0.80758 27.3319C2.66553 24.0945 7.3536 15.924 9.79487 11.6689C10.742 10.0178 12.4996 9 14.4027 9H68.938C70.0857 9 71.1428 9.62395 71.6991 10.6268C72.2552 11.6311 72.2227 12.8572 71.6141 13.8303C69.5899 17.0663 67.0634 21.1062 65.7494 23.2067C65.5707 23.4923 65.5611 23.8523 65.7245 24.1473C65.8877 24.4424 66.1982 24.6251 66.535 24.6251C69.448 24.6251 75.5484 24.6251 79.8223 24.6251C82.3898 24.6251 84.471 26.7066 84.471 29.274V52.7691C84.471 55.3947 83.8057 57.9784 82.5371 60.2765C80.939 63.1728 78.3456 67.2763 76.7102 70.2403C75.4301 72.56 72.9904 74 70.3411 74H19.1583C17.9853 74 16.9082 73.3517 16.3589 72.315C15.8095 71.2797 15.8777 70.0237 16.536 69.0533C18.7674 65.7632 21.4462 61.8126 22.3366 60.4998Z"
|
|
67
|
-
fill="#395C6B" />
|
|
68
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
69
|
-
d="M30.2249 58.0352C29.1545 58.0352 28.1511 58.5563 27.5344 59.4306C25.8334 61.8437 22.3568 66.7755 20.6071 69.2577C20.4026 69.5487 20.3769 69.9276 20.5402 70.2429C20.7036 70.5583 21.0288 70.7559 21.3835 70.7559C29.2185 70.7559 59.6145 70.7559 69.1579 70.7559C70.9171 70.7559 72.542 69.8153 73.419 68.29C74.6679 66.1178 76.8133 62.9603 78.0993 60.7231C78.4186 60.1682 78.4177 59.4847 78.097 58.9312C77.7763 58.3763 77.1844 58.0352 76.5441 58.0352C66.8957 58.0352 37.6132 58.0352 30.2249 58.0352Z"
|
|
70
|
-
fill="#FFFBF9" />
|
|
71
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
72
|
-
d="M16.7542 44.3536C14.9549 44.359 13.2576 45.19 12.1493 46.6084C10.5674 48.6318 8.23064 51.6214 6.4953 53.841C6.06303 54.3932 5.98399 55.1443 6.29162 55.775C6.59911 56.407 7.23968 56.8063 7.94155 56.8063H24.4549C25.0379 55.576 26.278 54.7911 27.6401 54.7911C34.1708 54.7911 53.1912 54.7911 59.5546 54.7911C60.8602 54.7911 62.0719 54.1117 62.7536 52.9978C63.9647 51.0205 65.8999 47.8603 67.0955 45.9073C67.3097 45.5568 67.3179 45.1183 67.1166 44.761C66.9154 44.4023 66.5363 44.1817 66.1258 44.1831C57.8228 44.2115 26.4211 44.3198 16.7542 44.3536Z"
|
|
73
|
-
fill="#FFFBF9" />
|
|
74
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
75
|
-
d="M67.4768 52.1533C67.1457 52.6852 67.129 53.3552 67.4334 53.9033C67.7378 54.4514 68.3153 54.7911 68.942 54.7911H78.2027C78.9173 54.7911 79.6027 54.5069 80.1079 54.0021C80.6133 53.4959 80.8971 52.8111 80.8971 52.0965C80.8971 46.9197 80.8971 35.6431 80.8971 30.5097C80.8971 29.0507 79.7149 27.8692 78.2565 27.8692C69.8008 27.8692 43.4566 27.8692 35.056 27.8692C33.4357 27.8692 31.9278 28.6975 31.0586 30.0644C29.526 32.4762 27.742 36.3198 26.2329 38.6937C25.9648 39.1146 25.9477 39.6492 26.1884 40.0877C26.4289 40.5262 26.889 40.7983 27.3888 40.7983H68.4092C69.6466 40.7983 70.7869 41.4696 71.3879 42.5509C71.9888 43.6323 71.9561 44.9546 71.3022 46.0062C69.9995 48.0999 68.554 50.4223 67.4768 52.1533Z"
|
|
76
|
-
fill="#FFFBF9" />
|
|
77
|
-
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
78
|
-
d="M59.9333 24.625C60.288 24.625 60.6187 24.4451 60.8126 24.1487C61.8367 22.5801 65.143 17.517 66.9494 14.7506C67.1889 14.3838 67.2083 13.9142 66.9997 13.5298C66.791 13.1441 66.3881 12.9046 65.9499 12.9046C57.9893 12.9046 30.6062 12.9046 19.215 12.9046C17.88 12.9046 16.5998 13.4337 15.6558 14.3784C14.712 15.3217 14.1816 16.602 14.1816 17.9379C14.1816 22.9482 14.1816 30.6112 14.1816 35.7379C14.1816 37.14 14.7557 38.4799 15.7702 39.4475C16.7847 40.4152 18.151 40.9241 19.5512 40.8578C19.5515 40.8578 20.2109 40.8578 20.2109 40.8578C20.2282 40.7157 25.538 31.549 28.4687 27.0544C29.4576 25.5386 31.1453 24.625 32.9555 24.625C39.7998 24.625 56.6284 24.625 59.9333 24.625Z"
|
|
79
|
-
fill="#FFFBF9" />
|
|
80
|
-
</svg>
|
|
81
|
-
|
|
82
|
-
<p>This placeholder site is deployed when running `sst start`.</p>
|
|
83
|
-
<p>For local dev, run your static site locally.</p>
|
|
84
|
-
<p>
|
|
85
|
-
<a href="https://docs.sst.dev/constructs/StaticSite">Learn more about the StaticSite construct</a>
|
|
86
|
-
</p>
|
|
87
|
-
</section>
|
|
88
|
-
</body>
|
|
89
|
-
|
|
90
|
-
</html>
|
package/src/app.ts
DELETED
|
@@ -1,140 +0,0 @@
|
|
|
1
|
-
import fs from "fs/promises";
|
|
2
|
-
import fsSync from "fs";
|
|
3
|
-
import path from "path";
|
|
4
|
-
import { Logger } from "./logger.js";
|
|
5
|
-
import { Context } from "./context/context.js";
|
|
6
|
-
import { VisibleError } from "./error.js";
|
|
7
|
-
|
|
8
|
-
export interface Project {
|
|
9
|
-
name: string;
|
|
10
|
-
stage?: string;
|
|
11
|
-
profile?: string;
|
|
12
|
-
region?: string;
|
|
13
|
-
main?: string;
|
|
14
|
-
ssmPrefix?: string;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
const DEFAULTS = {
|
|
18
|
-
main: "stacks/index.ts",
|
|
19
|
-
stage: undefined,
|
|
20
|
-
ssmPrefix: undefined
|
|
21
|
-
} as const;
|
|
22
|
-
|
|
23
|
-
type ProjectWithDefaults = Project &
|
|
24
|
-
Required<
|
|
25
|
-
{
|
|
26
|
-
[key in keyof typeof DEFAULTS]: Exclude<Project[key], undefined>;
|
|
27
|
-
}
|
|
28
|
-
> & {
|
|
29
|
-
paths: {
|
|
30
|
-
root: string;
|
|
31
|
-
out: string;
|
|
32
|
-
};
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
const ProjectContext = Context.create<ProjectWithDefaults>();
|
|
36
|
-
|
|
37
|
-
export function useProject() {
|
|
38
|
-
return ProjectContext.use();
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
const CONFIG_EXTENSIONS = [".config.cjs", ".config.mjs", ".config.js", ".json"];
|
|
42
|
-
|
|
43
|
-
interface GlobalOptions {
|
|
44
|
-
profile?: string;
|
|
45
|
-
stage?: string;
|
|
46
|
-
root?: string;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export async function initProject(globals: GlobalOptions) {
|
|
50
|
-
const root = globals.root || (await findRoot());
|
|
51
|
-
Logger.debug("Using project root", root);
|
|
52
|
-
const out = path.join(root, ".sst");
|
|
53
|
-
await fs.mkdir(out, {
|
|
54
|
-
recursive: true
|
|
55
|
-
});
|
|
56
|
-
Logger.debug("Using project out", out);
|
|
57
|
-
|
|
58
|
-
async function load() {
|
|
59
|
-
for (const ext of CONFIG_EXTENSIONS) {
|
|
60
|
-
const file = path.join(root, "sst" + ext);
|
|
61
|
-
if (file.endsWith("js")) {
|
|
62
|
-
let fn;
|
|
63
|
-
try {
|
|
64
|
-
fn = await import(file);
|
|
65
|
-
} catch (err) {
|
|
66
|
-
continue;
|
|
67
|
-
}
|
|
68
|
-
const config = await fn.default(globals);
|
|
69
|
-
return {
|
|
70
|
-
...DEFAULTS,
|
|
71
|
-
...config,
|
|
72
|
-
stage: globals.stage || (await usePersonalStage(out)),
|
|
73
|
-
profile: globals.profile || config.profile
|
|
74
|
-
} as ProjectWithDefaults;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
if (file.endsWith(".json")) {
|
|
78
|
-
try {
|
|
79
|
-
const data = await fs.readFile(file);
|
|
80
|
-
return Object.assign(
|
|
81
|
-
DEFAULTS,
|
|
82
|
-
JSON.parse(data.toString("utf8"))
|
|
83
|
-
) as ProjectWithDefaults;
|
|
84
|
-
} catch {
|
|
85
|
-
continue;
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
throw new VisibleError(
|
|
90
|
-
"Could not found a configuration file",
|
|
91
|
-
"Make sure one of the following exists",
|
|
92
|
-
" - sst.config.cjs",
|
|
93
|
-
" - sst.config.mjs",
|
|
94
|
-
" - sst.config.js",
|
|
95
|
-
" - sst.json"
|
|
96
|
-
);
|
|
97
|
-
}
|
|
98
|
-
const project = await load();
|
|
99
|
-
project.ssmPrefix =
|
|
100
|
-
project.ssmPrefix || `/sst/${project.name}/${project.stage}/`;
|
|
101
|
-
project.paths = {
|
|
102
|
-
root,
|
|
103
|
-
out
|
|
104
|
-
};
|
|
105
|
-
Logger.debug("Config loaded", project);
|
|
106
|
-
|
|
107
|
-
ProjectContext.provide(project);
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
async function usePersonalStage(out: string) {
|
|
111
|
-
try {
|
|
112
|
-
const result = await fs.readFile(path.join(out, "stage"));
|
|
113
|
-
return result.toString("utf8").trim();
|
|
114
|
-
} catch {
|
|
115
|
-
return;
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
async function findRoot() {
|
|
120
|
-
Logger.debug("Searching for project root...");
|
|
121
|
-
async function find(dir: string): Promise<string> {
|
|
122
|
-
if (dir === "/")
|
|
123
|
-
throw new VisibleError(
|
|
124
|
-
"Could not found a configuration file",
|
|
125
|
-
"Make sure one of the following exists",
|
|
126
|
-
...CONFIG_EXTENSIONS.map(ext => ` - sst${ext}`)
|
|
127
|
-
);
|
|
128
|
-
for (const ext of CONFIG_EXTENSIONS) {
|
|
129
|
-
const configPath = path.join(dir, `sst${ext}`);
|
|
130
|
-
Logger.debug("Searching", configPath);
|
|
131
|
-
if (fsSync.existsSync(configPath)) {
|
|
132
|
-
Logger.debug("Found config", configPath);
|
|
133
|
-
return dir;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
return await find(path.join(dir, ".."));
|
|
137
|
-
}
|
|
138
|
-
const result = await find(process.cwd());
|
|
139
|
-
return result;
|
|
140
|
-
}
|
package/src/bootstrap.ts
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { GetParametersCommand, SSMClient } from "@aws-sdk/client-ssm";
|
|
2
|
-
import { Context } from "./context/context.js";
|
|
3
|
-
import { useAWSClient } from "./credentials.js";
|
|
4
|
-
import { Logger } from "./logger.js";
|
|
5
|
-
|
|
6
|
-
const SSM_NAME_VERSION = `/sst/bootstrap/version`;
|
|
7
|
-
const SSM_NAME_STACK_NAME = `/sst/bootstrap/stack-name`;
|
|
8
|
-
const SSM_NAME_BUCKET_NAME = `/sst/bootstrap/bucket-name`;
|
|
9
|
-
|
|
10
|
-
export const useBootstrap = Context.memo(async () => {
|
|
11
|
-
Logger.debug("Initializing bootstrap context");
|
|
12
|
-
const ssm = useAWSClient(SSMClient);
|
|
13
|
-
const result = await ssm.send(
|
|
14
|
-
new GetParametersCommand({
|
|
15
|
-
Names: [SSM_NAME_VERSION, SSM_NAME_STACK_NAME, SSM_NAME_BUCKET_NAME],
|
|
16
|
-
})
|
|
17
|
-
);
|
|
18
|
-
|
|
19
|
-
const ret = {
|
|
20
|
-
version: result.Parameters!.find((p) => p.Name === SSM_NAME_VERSION)!.Value,
|
|
21
|
-
bucket: result.Parameters!.find((p) => p.Name === SSM_NAME_BUCKET_NAME)!
|
|
22
|
-
.Value,
|
|
23
|
-
stack: result.Parameters!.find((p) => p.Name === SSM_NAME_STACK_NAME)!
|
|
24
|
-
.Value,
|
|
25
|
-
};
|
|
26
|
-
Logger.debug("Loaded bootstrap info: ", JSON.stringify(ret));
|
|
27
|
-
return ret;
|
|
28
|
-
});
|
package/src/bus.ts
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import crypto from "crypto";
|
|
2
|
-
import { Context } from "./context/context.js";
|
|
3
|
-
import { Logger } from "./logger.js";
|
|
4
|
-
|
|
5
|
-
export interface Events {}
|
|
6
|
-
|
|
7
|
-
export type EventTypes = keyof Events;
|
|
8
|
-
|
|
9
|
-
const DO_NOT_LOG = new Set<keyof Events>(["stacks.metadata"]);
|
|
10
|
-
|
|
11
|
-
export type EventPayload<Type extends EventTypes = EventTypes> = {
|
|
12
|
-
type: Type;
|
|
13
|
-
sourceID: string;
|
|
14
|
-
properties: Events[Type];
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
type Subscription = {
|
|
18
|
-
type: EventTypes;
|
|
19
|
-
cb: (payload: any) => void;
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
export const useBus = Context.memo(() => {
|
|
23
|
-
const subscriptions: Record<string, Subscription[]> = {};
|
|
24
|
-
|
|
25
|
-
function subscribers(type: EventTypes) {
|
|
26
|
-
let arr = subscriptions[type];
|
|
27
|
-
if (!arr) {
|
|
28
|
-
arr = [];
|
|
29
|
-
subscriptions[type] = arr;
|
|
30
|
-
}
|
|
31
|
-
return arr;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
const sourceID = crypto.randomBytes(16).toString("hex");
|
|
35
|
-
|
|
36
|
-
const result = {
|
|
37
|
-
sourceID,
|
|
38
|
-
publish<Type extends EventTypes>(type: Type, properties: Events[Type]) {
|
|
39
|
-
const payload: EventPayload<Type> = {
|
|
40
|
-
type,
|
|
41
|
-
properties,
|
|
42
|
-
sourceID,
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
if (!DO_NOT_LOG.has(type)) {
|
|
46
|
-
Logger.debug(`Publishing event ${JSON.stringify(payload)}`);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
for (const sub of subscribers(type)) sub.cb(payload);
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
unsubscribe(sub: Subscription) {
|
|
53
|
-
const arr = subscribers(sub.type);
|
|
54
|
-
const index = arr.indexOf(sub);
|
|
55
|
-
if (!index) return;
|
|
56
|
-
arr.splice(index, 1);
|
|
57
|
-
},
|
|
58
|
-
|
|
59
|
-
subscribe<Type extends EventTypes>(
|
|
60
|
-
type: Type,
|
|
61
|
-
cb: (payload: EventPayload<Type>) => void
|
|
62
|
-
) {
|
|
63
|
-
const sub: Subscription = {
|
|
64
|
-
type,
|
|
65
|
-
cb,
|
|
66
|
-
};
|
|
67
|
-
subscribers(type).push(sub);
|
|
68
|
-
return sub;
|
|
69
|
-
},
|
|
70
|
-
forward<T extends EventTypes[]>(..._types: T) {
|
|
71
|
-
return <Type extends T[number]>(
|
|
72
|
-
type: Type,
|
|
73
|
-
cb: (payload: EventPayload<Type>) => void
|
|
74
|
-
) => {
|
|
75
|
-
return this.subscribe(type, cb);
|
|
76
|
-
};
|
|
77
|
-
},
|
|
78
|
-
};
|
|
79
|
-
|
|
80
|
-
return result;
|
|
81
|
-
});
|
package/src/cache.ts
DELETED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import path from "path";
|
|
2
|
-
import fs from "fs/promises";
|
|
3
|
-
import { useProject } from "./app.js";
|
|
4
|
-
import { Logger } from "./logger.js";
|
|
5
|
-
import { Context } from "./context/context.js";
|
|
6
|
-
|
|
7
|
-
export const useCache = Context.memo(async () => {
|
|
8
|
-
const project = useProject();
|
|
9
|
-
const cache = path.join(project.paths.out, "cache");
|
|
10
|
-
await fs.mkdir(cache, {
|
|
11
|
-
recursive: true,
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
async function write(key: string, data: string) {
|
|
15
|
-
const full = path.join(cache, key);
|
|
16
|
-
Logger.debug("Writing cache", full, data.length, "bytes");
|
|
17
|
-
await fs.writeFile(full, data);
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
async function read(key: string) {
|
|
21
|
-
const full = path.join(cache, key);
|
|
22
|
-
try {
|
|
23
|
-
const data = await fs.readFile(full);
|
|
24
|
-
return data.toString();
|
|
25
|
-
} catch {
|
|
26
|
-
return null;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
return {
|
|
31
|
-
write,
|
|
32
|
-
read,
|
|
33
|
-
};
|
|
34
|
-
});
|