@webiny/project-aws 6.6.0-alpha.10 → 6.6.0-alpha.11
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/AwsProjectSdk.d.ts +38 -0
- package/AwsProjectSdk.js +61 -0
- package/AwsProjectSdk.js.map +1 -0
- package/abstractions/features/DestroyApp.d.ts +18 -0
- package/abstractions/features/DestroyApp.js +5 -0
- package/abstractions/features/DestroyApp.js.map +1 -0
- package/abstractions/features/ExportStack.d.ts +18 -0
- package/abstractions/features/ExportStack.js +5 -0
- package/abstractions/features/ExportStack.js.map +1 -0
- package/abstractions/features/GetAppOutput.d.ts +18 -0
- package/abstractions/features/GetAppOutput.js +5 -0
- package/abstractions/features/GetAppOutput.js.map +1 -0
- package/abstractions/features/GetAppStackOutput.d.ts +18 -0
- package/abstractions/features/GetAppStackOutput.js +5 -0
- package/abstractions/features/GetAppStackOutput.js.map +1 -0
- package/abstractions/features/GetPulumiResourceNamePrefix.d.ts +7 -0
- package/abstractions/features/GetPulumiResourceNamePrefix.js +5 -0
- package/abstractions/features/GetPulumiResourceNamePrefix.js.map +1 -0
- package/abstractions/features/RefreshApp.d.ts +18 -0
- package/abstractions/features/RefreshApp.js +5 -0
- package/abstractions/features/RefreshApp.js.map +1 -0
- package/abstractions/features/RunPulumiCommand.d.ts +19 -0
- package/abstractions/features/RunPulumiCommand.js +5 -0
- package/abstractions/features/RunPulumiCommand.js.map +1 -0
- package/abstractions/index.d.ts +21 -0
- package/abstractions/index.js +21 -0
- package/abstractions/pulumiTypes.d.ts +3 -0
- package/abstractions/services/GetPulumiService.d.ts +20 -0
- package/abstractions/services/GetPulumiService.js +5 -0
- package/abstractions/services/GetPulumiService.js.map +1 -0
- package/abstractions/services/GetPulumiVersionService.d.ts +12 -0
- package/abstractions/services/GetPulumiVersionService.js +5 -0
- package/abstractions/services/GetPulumiVersionService.js.map +1 -0
- package/abstractions/services/IsRemotePulumiBackendService.d.ts +7 -0
- package/abstractions/services/IsRemotePulumiBackendService.js +5 -0
- package/abstractions/services/IsRemotePulumiBackendService.js.map +1 -0
- package/abstractions/services/ListAppLambdaFunctionsService.d.ts +23 -0
- package/abstractions/services/ListAppLambdaFunctionsService.js +5 -0
- package/abstractions/services/ListAppLambdaFunctionsService.js.map +1 -0
- package/abstractions/services/ListDeployedEnvironmentsService.d.ts +12 -0
- package/abstractions/services/ListDeployedEnvironmentsService.js +5 -0
- package/abstractions/services/ListDeployedEnvironmentsService.js.map +1 -0
- package/abstractions/services/PulumiExportService.d.ts +13 -0
- package/abstractions/services/PulumiExportService.js +6 -0
- package/abstractions/services/PulumiExportService.js.map +1 -0
- package/abstractions/services/PulumiGetConfigPassphraseService.d.ts +7 -0
- package/abstractions/services/PulumiGetConfigPassphraseService.js +5 -0
- package/abstractions/services/PulumiGetConfigPassphraseService.js.map +1 -0
- package/abstractions/services/PulumiGetSecretsProviderService.d.ts +7 -0
- package/abstractions/services/PulumiGetSecretsProviderService.js +5 -0
- package/abstractions/services/PulumiGetSecretsProviderService.js.map +1 -0
- package/abstractions/services/PulumiGetStackOutputService.d.ts +13 -0
- package/abstractions/services/PulumiGetStackOutputService.js +5 -0
- package/abstractions/services/PulumiGetStackOutputService.js.map +1 -0
- package/abstractions/services/PulumiImportService.d.ts +8 -0
- package/abstractions/services/PulumiImportService.js +5 -0
- package/abstractions/services/PulumiImportService.js.map +1 -0
- package/abstractions/services/PulumiLoginService.d.ts +19 -0
- package/abstractions/services/PulumiLoginService.js +5 -0
- package/abstractions/services/PulumiLoginService.js.map +1 -0
- package/abstractions/services/PulumiSelectStackService.d.ts +10 -0
- package/abstractions/services/PulumiSelectStackService.js +5 -0
- package/abstractions/services/PulumiSelectStackService.js.map +1 -0
- package/abstractions/services/StackOutputCacheService.d.ts +10 -0
- package/abstractions/services/StackOutputCacheService.js +5 -0
- package/abstractions/services/StackOutputCacheService.js.map +1 -0
- package/abstractions/services/WatchedLambdaFunctionsService.d.ts +28 -0
- package/abstractions/services/WatchedLambdaFunctionsService.js +5 -0
- package/abstractions/services/WatchedLambdaFunctionsService.js.map +1 -0
- package/api.d.ts +1 -15
- package/decorators/DeployAppClearWatchedLambdaFunctions.d.ts +20 -0
- package/decorators/DeployAppClearWatchedLambdaFunctions.js +35 -0
- package/decorators/DeployAppClearWatchedLambdaFunctions.js.map +1 -0
- package/decorators/DeployAppRefreshStackOutputCache.d.ts +20 -0
- package/decorators/DeployAppRefreshStackOutputCache.js +34 -0
- package/decorators/DeployAppRefreshStackOutputCache.js.map +1 -0
- package/decorators/DeployAppWithHooks.d.ts +25 -0
- package/decorators/DeployAppWithHooks.js +58 -0
- package/decorators/DeployAppWithHooks.js.map +1 -0
- package/decorators/DeployAppWithWatchedLambdaReplacement.d.ts +20 -0
- package/decorators/DeployAppWithWatchedLambdaReplacement.js +42 -0
- package/decorators/DeployAppWithWatchedLambdaReplacement.js.map +1 -0
- package/decorators/DestroyAppClearStackOutputCache.d.ts +28 -0
- package/decorators/DestroyAppClearStackOutputCache.js +31 -0
- package/decorators/DestroyAppClearStackOutputCache.js.map +1 -0
- package/decorators/GetPulumiServiceWithDownloadInfo.d.ts +13 -0
- package/decorators/GetPulumiServiceWithDownloadInfo.js +28 -0
- package/decorators/GetPulumiServiceWithDownloadInfo.js.map +1 -0
- package/decorators/ProjectInfoWithPulumi.d.ts +34 -0
- package/decorators/ProjectInfoWithPulumi.js +36 -0
- package/decorators/ProjectInfoWithPulumi.js.map +1 -0
- package/extensions/ApiRoute.d.ts +7 -16
- package/extensions/ApiRoute.js +4 -66
- package/extensions/ApiRoute.js.map +1 -1
- package/extensions/OpenSearch/EnsureOsServiceRoleBeforeCoreDeploy.d.ts +3 -2
- package/extensions/OpenSearch/EnsureOsServiceRoleBeforeCoreDeploy.js +2 -1
- package/extensions/OpenSearch/EnsureOsServiceRoleBeforeCoreDeploy.js.map +1 -1
- package/extensions/OpenSearch/EnsureOsWasDeployed.d.ts +2 -2
- package/extensions/OpenSearch/EnsureOsWasDeployed.js +1 -2
- package/extensions/OpenSearch/EnsureOsWasDeployed.js.map +1 -1
- package/extensions/OpenSearch.js +2 -2
- package/extensions/OpenSearch.js.map +1 -1
- package/extensions/ProjectAws/AutoInstall/AutoInstallAfterApiDeploy.d.ts +2 -2
- package/extensions/ProjectAws/AutoInstall/AutoInstallAfterApiDeploy.js +2 -1
- package/extensions/ProjectAws/AutoInstall/AutoInstallAfterApiDeploy.js.map +1 -1
- package/extensions/ProjectAws/BlueGreenDeployments/EnsureVariantBeforeDeploy.d.ts +3 -2
- package/extensions/ProjectAws/BlueGreenDeployments/EnsureVariantBeforeDeploy.js +2 -1
- package/extensions/ProjectAws/BlueGreenDeployments/EnsureVariantBeforeDeploy.js.map +1 -1
- package/extensions/ProjectAws/BlueGreenDeployments/PrintDeploymentInfoAfterDeploy.d.ts +5 -2
- package/extensions/ProjectAws/BlueGreenDeployments/PrintDeploymentInfoAfterDeploy.js +3 -1
- package/extensions/ProjectAws/BlueGreenDeployments/PrintDeploymentInfoAfterDeploy.js.map +1 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeAdminBuild.d.ts +3 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeAdminBuild.js +2 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeAdminBuild.js.map +1 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeAdminWatch.d.ts +3 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeAdminWatch.js +2 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeAdminWatch.js.map +1 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeWatch.d.ts +3 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeWatch.js +2 -1
- package/extensions/ProjectAws/EnsureApiDeployedBeforeWatch.js.map +1 -1
- package/extensions/ProjectAws/EnsureAwsCredentialsBeforeDeploy.d.ts +3 -2
- package/extensions/ProjectAws/EnsureAwsCredentialsBeforeDeploy.js +2 -1
- package/extensions/ProjectAws/EnsureAwsCredentialsBeforeDeploy.js.map +1 -1
- package/extensions/ProjectAws/EnsureCoreDeployedBeforeApiDeploy.d.ts +4 -2
- package/extensions/ProjectAws/EnsureCoreDeployedBeforeApiDeploy.js +3 -1
- package/extensions/ProjectAws/EnsureCoreDeployedBeforeApiDeploy.js.map +1 -1
- package/extensions/ProjectAws/EnsureTelemetryEnabledForOss.d.ts +6 -2
- package/extensions/ProjectAws/EnsureTelemetryEnabledForOss.js +2 -1
- package/extensions/ProjectAws/EnsureTelemetryEnabledForOss.js.map +1 -1
- package/extensions/ProjectAws/TelemetryNoLongerNewUser.d.ts +2 -2
- package/extensions/ProjectAws/TelemetryNoLongerNewUser.js +1 -1
- package/extensions/ProjectAws/TelemetryNoLongerNewUser.js.map +1 -1
- package/extensions/ProjectAws/UploadAdminAppToS3.d.ts +4 -2
- package/extensions/ProjectAws/UploadAdminAppToS3.js +2 -2
- package/extensions/ProjectAws/UploadAdminAppToS3.js.map +1 -1
- package/extensions/ProjectAws/ValidateEncryptionBeforeDeploy.d.ts +5 -2
- package/extensions/ProjectAws/ValidateEncryptionBeforeDeploy.js +2 -1
- package/extensions/ProjectAws/ValidateEncryptionBeforeDeploy.js.map +1 -1
- package/extensions/ProjectAws/ValidateProductionPulumiState.d.ts +5 -2
- package/extensions/ProjectAws/ValidateProductionPulumiState.js +3 -1
- package/extensions/ProjectAws/ValidateProductionPulumiState.js.map +1 -1
- package/extensions/ProjectAws/definitions.js +5 -1
- package/extensions/ProjectAws/definitions.js.map +1 -1
- package/extensions/ProjectAws.js +2 -1
- package/extensions/ProjectAws.js.map +1 -1
- package/extensions/RegisterRoutesPulumi.js +2 -2
- package/extensions/RegisterRoutesPulumi.js.map +1 -1
- package/extensions/definitions.js +0 -2
- package/extensions/definitions.js.map +1 -1
- package/extensions/registerExtensionImplementations.js +2 -1
- package/extensions/registerExtensionImplementations.js.map +1 -1
- package/extensions/toApiGatewayPath.d.ts +2 -0
- package/extensions/toApiGatewayPath.js +6 -0
- package/extensions/toApiGatewayPath.js.map +1 -0
- package/features/DeployApp/DeployApp.d.ts +22 -0
- package/features/DeployApp/DeployApp.js +91 -0
- package/features/DeployApp/DeployApp.js.map +1 -0
- package/features/DeployApp/index.d.ts +1 -0
- package/features/DeployApp/index.js +1 -0
- package/features/DestroyApp/DestroyApp.d.ts +20 -0
- package/features/DestroyApp/DestroyApp.js +70 -0
- package/features/DestroyApp/DestroyApp.js.map +1 -0
- package/features/DestroyApp/index.d.ts +1 -0
- package/features/DestroyApp/index.js +1 -0
- package/features/ExportStack/ExportStack.d.ts +12 -0
- package/features/ExportStack/ExportStack.js +28 -0
- package/features/ExportStack/ExportStack.js.map +1 -0
- package/features/ExportStack/index.d.ts +1 -0
- package/features/ExportStack/index.js +1 -0
- package/features/GetAppOutput/GetAppOutput.d.ts +16 -0
- package/features/GetAppOutput/GetAppOutput.js +55 -0
- package/features/GetAppOutput/GetAppOutput.js.map +1 -0
- package/features/GetAppOutput/index.d.ts +1 -0
- package/features/GetAppOutput/index.js +1 -0
- package/features/GetAppStackOutput/GetAppStackOutput.d.ts +13 -0
- package/features/GetAppStackOutput/GetAppStackOutput.js +28 -0
- package/features/GetAppStackOutput/GetAppStackOutput.js.map +1 -0
- package/features/GetAppStackOutput/index.d.ts +1 -0
- package/features/GetAppStackOutput/index.js +1 -0
- package/features/GetPulumiResourceNamePrefix/GetPulumiResourceNamePrefix.d.ts +8 -0
- package/features/GetPulumiResourceNamePrefix/GetPulumiResourceNamePrefix.js +26 -0
- package/features/GetPulumiResourceNamePrefix/GetPulumiResourceNamePrefix.js.map +1 -0
- package/features/GetPulumiResourceNamePrefix/index.d.ts +1 -0
- package/features/GetPulumiResourceNamePrefix/index.js +1 -0
- package/features/InvokeLambdaFunction.d.ts +1 -1
- package/features/InvokeLambdaFunction.js +1 -1
- package/features/InvokeLambdaFunction.js.map +1 -1
- package/features/RefreshApp/RefreshApp.d.ts +18 -0
- package/features/RefreshApp/RefreshApp.js +68 -0
- package/features/RefreshApp/RefreshApp.js.map +1 -0
- package/features/RefreshApp/index.d.ts +1 -0
- package/features/RefreshApp/index.js +1 -0
- package/features/RunPulumiCommand/RunPulumiCommand.d.ts +18 -0
- package/features/RunPulumiCommand/RunPulumiCommand.js +65 -0
- package/features/RunPulumiCommand/RunPulumiCommand.js.map +1 -0
- package/features/RunPulumiCommand/index.d.ts +1 -0
- package/features/RunPulumiCommand/index.js +1 -0
- package/features/Watch/AwsWatch.d.ts +9 -1
- package/features/Watch/AwsWatch.js +6 -2
- package/features/Watch/AwsWatch.js.map +1 -1
- package/features/Watch/getIotEndpoint.d.ts +2 -2
- package/features/Watch/getIotEndpoint.js.map +1 -1
- package/features/Watch/initInvocationForwarding.d.ts +9 -0
- package/features/Watch/initInvocationForwarding.js +91 -0
- package/features/Watch/initInvocationForwarding.js.map +1 -0
- package/features/Watch/localInvocationWorker.d.ts +1 -0
- package/features/Watch/localInvocationWorker.js +31 -0
- package/features/Watch/localInvocationWorker.js.map +1 -0
- package/features/Watch/replaceLambdaFunctions.d.ts +7 -3
- package/features/Watch/replaceLambdaFunctions.js.map +1 -1
- package/features/hooks/AdminAfterDeploy/AdminAfterDeploy.d.ts +7 -0
- package/features/hooks/AdminAfterDeploy/AdminAfterDeploy.js +25 -0
- package/features/hooks/AdminAfterDeploy/AdminAfterDeploy.js.map +1 -0
- package/features/hooks/AdminAfterDeploy/index.d.ts +1 -0
- package/features/hooks/AdminAfterDeploy/index.js +1 -0
- package/features/hooks/AdminBeforeDeploy/AdminBeforeDeploy.d.ts +7 -0
- package/features/hooks/AdminBeforeDeploy/AdminBeforeDeploy.js +25 -0
- package/features/hooks/AdminBeforeDeploy/AdminBeforeDeploy.js.map +1 -0
- package/features/hooks/AdminBeforeDeploy/index.d.ts +1 -0
- package/features/hooks/AdminBeforeDeploy/index.js +1 -0
- package/features/hooks/AfterDeploy/AfterDeploy.d.ts +7 -0
- package/features/hooks/AfterDeploy/AfterDeploy.js +25 -0
- package/features/hooks/AfterDeploy/AfterDeploy.js.map +1 -0
- package/features/hooks/AfterDeploy/index.d.ts +1 -0
- package/features/hooks/AfterDeploy/index.js +1 -0
- package/features/hooks/ApiAfterDeploy/ApiAfterDeploy.d.ts +7 -0
- package/features/hooks/ApiAfterDeploy/ApiAfterDeploy.js +25 -0
- package/features/hooks/ApiAfterDeploy/ApiAfterDeploy.js.map +1 -0
- package/features/hooks/ApiAfterDeploy/index.d.ts +1 -0
- package/features/hooks/ApiAfterDeploy/index.js +1 -0
- package/features/hooks/ApiBeforeDeploy/ApiBeforeDeploy.d.ts +7 -0
- package/features/hooks/ApiBeforeDeploy/ApiBeforeDeploy.js +25 -0
- package/features/hooks/ApiBeforeDeploy/ApiBeforeDeploy.js.map +1 -0
- package/features/hooks/ApiBeforeDeploy/index.d.ts +1 -0
- package/features/hooks/ApiBeforeDeploy/index.js +1 -0
- package/features/hooks/BeforeDeploy/BeforeDeploy.d.ts +7 -0
- package/features/hooks/BeforeDeploy/BeforeDeploy.js +25 -0
- package/features/hooks/BeforeDeploy/BeforeDeploy.js.map +1 -0
- package/features/hooks/BeforeDeploy/index.d.ts +1 -0
- package/features/hooks/BeforeDeploy/index.js +1 -0
- package/features/hooks/CoreAfterDeploy/CoreAfterDeploy.d.ts +7 -0
- package/features/hooks/CoreAfterDeploy/CoreAfterDeploy.js +25 -0
- package/features/hooks/CoreAfterDeploy/CoreAfterDeploy.js.map +1 -0
- package/features/hooks/CoreAfterDeploy/index.d.ts +1 -0
- package/features/hooks/CoreAfterDeploy/index.js +1 -0
- package/features/hooks/CoreBeforeDeploy/CoreBeforeDeploy.d.ts +7 -0
- package/features/hooks/CoreBeforeDeploy/CoreBeforeDeploy.js +25 -0
- package/features/hooks/CoreBeforeDeploy/CoreBeforeDeploy.js.map +1 -0
- package/features/hooks/CoreBeforeDeploy/index.d.ts +1 -0
- package/features/hooks/CoreBeforeDeploy/index.js +1 -0
- package/index.d.ts +2 -0
- package/index.js +2 -0
- package/infra.js +2 -2
- package/infra.js.map +1 -1
- package/package.json +15 -12
- package/pulumi/apps/blueGreen/types.d.ts +2 -2
- package/pulumi/apps/syncSystem/types.d.ts +2 -2
- package/pulumi/getAwsProjectSdk.d.ts +2 -12
- package/pulumi/getAwsProjectSdk.js +2 -3
- package/pulumi/getAwsProjectSdk.js.map +1 -1
- package/pulumi/getStackOutput.d.ts +4 -5
- package/pulumi/getStackOutput.js.map +1 -1
- package/pulumi/types.d.ts +2 -2
- package/registerAwsProjectFeatures.js +38 -9
- package/registerAwsProjectFeatures.js.map +1 -1
- package/services/AdminStackOutputService.d.ts +1 -1
- package/services/AdminStackOutputService.js +1 -1
- package/services/AdminStackOutputService.js.map +1 -1
- package/services/ApiStackOutputService.d.ts +1 -1
- package/services/ApiStackOutputService.js +1 -1
- package/services/ApiStackOutputService.js.map +1 -1
- package/services/AwsDeployInitHostingSdkService/AwsDeployInitHostingSdkService.d.ts +10 -0
- package/services/AwsDeployInitHostingSdkService/AwsDeployInitHostingSdkService.js +30 -0
- package/services/AwsDeployInitHostingSdkService/AwsDeployInitHostingSdkService.js.map +1 -0
- package/services/AwsPulumiInitHostingSdkService/AwsPulumiInitHostingSdkService.d.ts +9 -0
- package/services/AwsPulumiInitHostingSdkService/AwsPulumiInitHostingSdkService.js +24 -0
- package/services/AwsPulumiInitHostingSdkService/AwsPulumiInitHostingSdkService.js.map +1 -0
- package/services/CoreStackOutputService.d.ts +1 -1
- package/services/CoreStackOutputService.js +1 -1
- package/services/CoreStackOutputService.js.map +1 -1
- package/services/GetPulumiService/GetPulumiService.d.ts +3 -1
- package/services/GetPulumiService/GetPulumiService.js +2 -1
- package/services/GetPulumiService/GetPulumiService.js.map +1 -1
- package/services/GetPulumiVersionService/GetPulumiVersionService.d.ts +5 -0
- package/services/GetPulumiVersionService/GetPulumiVersionService.js +46 -0
- package/services/GetPulumiVersionService/GetPulumiVersionService.js.map +1 -0
- package/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.d.ts +14 -0
- package/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.js +15 -0
- package/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.js.map +1 -0
- package/services/IsRemotePulumiBackendService/index.d.ts +1 -0
- package/services/IsRemotePulumiBackendService/index.js +1 -0
- package/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.d.ts +20 -0
- package/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.js +63 -0
- package/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.js.map +1 -0
- package/services/ListAppLambdaFunctionsService/index.d.ts +1 -0
- package/services/ListAppLambdaFunctionsService/index.js +1 -0
- package/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.d.ts +8 -0
- package/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.js +31 -0
- package/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.js.map +1 -0
- package/services/ListDeployedEnvironmentsService/index.d.ts +1 -0
- package/services/ListDeployedEnvironmentsService/index.js +1 -0
- package/services/PulumiExportService/PulumiExportService.d.ts +16 -0
- package/services/PulumiExportService/PulumiExportService.js +54 -0
- package/services/PulumiExportService/PulumiExportService.js.map +1 -0
- package/services/PulumiExportService/index.d.ts +1 -0
- package/services/PulumiExportService/index.js +1 -0
- package/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.d.ts +5 -0
- package/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.js +15 -0
- package/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.js.map +1 -0
- package/services/PulumiGetConfigPassphraseService/index.d.ts +1 -0
- package/services/PulumiGetConfigPassphraseService/index.js +1 -0
- package/services/PulumiGetSecretsProviderService/PulumiGetSecretsProviderService.d.ts +5 -0
- package/services/PulumiGetSecretsProviderService/PulumiGetSecretsProviderService.js +15 -0
- package/services/PulumiGetSecretsProviderService/PulumiGetSecretsProviderService.js.map +1 -0
- package/services/PulumiGetSecretsProviderService/index.d.ts +1 -0
- package/services/PulumiGetSecretsProviderService/index.js +1 -0
- package/services/PulumiGetStackOutputService/PulumiGetStackOutputService.d.ts +16 -0
- package/services/PulumiGetStackOutputService/PulumiGetStackOutputService.js +69 -0
- package/services/PulumiGetStackOutputService/PulumiGetStackOutputService.js.map +1 -0
- package/services/PulumiGetStackOutputService/index.d.ts +1 -0
- package/services/PulumiGetStackOutputService/index.js +1 -0
- package/services/PulumiGetStackOutputService/mapStackOutput.d.ts +1 -0
- package/services/PulumiGetStackOutputService/mapStackOutput.js +22 -0
- package/services/PulumiGetStackOutputService/mapStackOutput.js.map +1 -0
- package/services/PulumiImportService/PulumiImportService.d.ts +13 -0
- package/services/PulumiImportService/PulumiImportService.js +64 -0
- package/services/PulumiImportService/PulumiImportService.js.map +1 -0
- package/services/PulumiImportService/index.d.ts +1 -0
- package/services/PulumiImportService/index.js +1 -0
- package/services/PulumiLoginService/PulumiLoginService.d.ts +13 -0
- package/services/PulumiLoginService/PulumiLoginService.js +59 -0
- package/services/PulumiLoginService/PulumiLoginService.js.map +1 -0
- package/services/PulumiLoginService/index.d.ts +1 -0
- package/services/PulumiLoginService/index.js +1 -0
- package/services/PulumiSelectStackService/PulumiSelectStackService.d.ts +20 -0
- package/services/PulumiSelectStackService/PulumiSelectStackService.js +106 -0
- package/services/PulumiSelectStackService/PulumiSelectStackService.js.map +1 -0
- package/services/PulumiSelectStackService/index.d.ts +1 -0
- package/services/PulumiSelectStackService/index.js +1 -0
- package/services/StackOutputCacheService/StackOutputCacheService.d.ts +21 -0
- package/services/StackOutputCacheService/StackOutputCacheService.js +90 -0
- package/services/StackOutputCacheService/StackOutputCacheService.js.map +1 -0
- package/services/StackOutputCacheService/index.d.ts +1 -0
- package/services/StackOutputCacheService/index.js +1 -0
- package/services/WatchedLambdaFunctionsService/WatchedLambdaFunctionsService.d.ts +14 -0
- package/services/WatchedLambdaFunctionsService/WatchedLambdaFunctionsService.js +55 -0
- package/services/WatchedLambdaFunctionsService/WatchedLambdaFunctionsService.js.map +1 -0
- package/services/WatchedLambdaFunctionsService/index.d.ts +1 -0
- package/services/WatchedLambdaFunctionsService/index.js +1 -0
- package/utils/withPulumiConfigPassphrase.d.ts +1 -0
- package/utils/withPulumiConfigPassphrase.js +7 -0
- package/utils/withPulumiConfigPassphrase.js.map +1 -0
- package/extensions/routePath.d.ts +0 -20
- package/extensions/routePath.js +0 -13
- package/extensions/routePath.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GetAppStackOutput } from "
|
|
1
|
+
import { GetAppStackOutput } from "../abstractions/features/GetAppStackOutput.js";
|
|
2
2
|
import { ApiStackOutputService } from "@webiny/project-extensions-aws/abstractions/index.js";
|
|
3
3
|
class DefaultApiStackOutputServiceAbstraction {
|
|
4
4
|
constructor(getAppStackOutput){
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"services/ApiStackOutputService.js","sources":["../../src/services/ApiStackOutputService.ts"],"sourcesContent":["import { GetAppStackOutput } from \"
|
|
1
|
+
{"version":3,"file":"services/ApiStackOutputService.js","sources":["../../src/services/ApiStackOutputService.ts"],"sourcesContent":["import { GetAppStackOutput } from \"~/abstractions/features/GetAppStackOutput.js\";\nimport { ApiStackOutputService as ApiStackOutputServiceAbstraction } from \"@webiny/project-extensions-aws/abstractions/index.js\";\n\nexport class DefaultApiStackOutputServiceAbstraction\n implements ApiStackOutputServiceAbstraction.Interface\n{\n constructor(private readonly getAppStackOutput: GetAppStackOutput.Interface) {}\n\n async execute<\n TOutput extends ApiStackOutputServiceAbstraction.Output =\n ApiStackOutputServiceAbstraction.Output\n >(): Promise<TOutput | null> {\n return this.getAppStackOutput.execute<TOutput>(\"api\");\n }\n}\n\nexport const ApiStackOutputService = ApiStackOutputServiceAbstraction.createImplementation({\n implementation: DefaultApiStackOutputServiceAbstraction,\n dependencies: [GetAppStackOutput]\n});\n"],"names":["DefaultApiStackOutputServiceAbstraction","getAppStackOutput","ApiStackOutputService","ApiStackOutputServiceAbstraction","GetAppStackOutput"],"mappings":";;AAGO,MAAMA;IAGT,YAA6BC,iBAA8C,CAAE;aAAhDA,iBAAiB,GAAjBA;IAAiD;IAE9E,MAAM,UAGuB;QACzB,OAAO,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAU;IACnD;AACJ;AAEO,MAAMC,8CAAwBC,sBAAAA,oBAAqD,CAAC;IACvF,gBAAgBH;IAChB,cAAc;QAACI;KAAkB;AACrC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { InitHostingSdkService } from "@webiny/project/abstractions/index.js";
|
|
2
|
+
/**
|
|
3
|
+
* The CLI side of deploying: the deploy hooks the project config names, and the decorators around
|
|
4
|
+
* deploy, destroy and the Pulumi CLI download. Registered here, and only here, because the
|
|
5
|
+
* container doesn't de-duplicate decorators: registering one twice wraps twice.
|
|
6
|
+
*/
|
|
7
|
+
export declare class AwsDeployInitHostingSdkService implements InitHostingSdkService.Interface {
|
|
8
|
+
execute({ container, projectExtensions, project }: InitHostingSdkService.Params): Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
export declare const awsDeployInitHostingSdkService: import("@webiny/di").Implementation<typeof AwsDeployInitHostingSdkService>;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { InitHostingSdkService } from "@webiny/project/abstractions/index.js";
|
|
3
|
+
import { registerSrcExtensions } from "@webiny/project/utils/index.js";
|
|
4
|
+
import { deployHooks } from "@webiny/project-extensions-aws/extensions/hooks/deployHooks.js";
|
|
5
|
+
import { deployAppClearWatchedLambdaFunctions } from "../../decorators/DeployAppClearWatchedLambdaFunctions.js";
|
|
6
|
+
import { deployAppRefreshStackOutputCache } from "../../decorators/DeployAppRefreshStackOutputCache.js";
|
|
7
|
+
import { deployAppWithHooks } from "../../decorators/DeployAppWithHooks.js";
|
|
8
|
+
import { deployAppWithWatchedLambdaReplacement } from "../../decorators/DeployAppWithWatchedLambdaReplacement.js";
|
|
9
|
+
import { destroyAppClearStackOutputCache } from "../../decorators/DestroyAppClearStackOutputCache.js";
|
|
10
|
+
import { getPulumiServiceWithDownloadInfo } from "../../decorators/GetPulumiServiceWithDownloadInfo.js";
|
|
11
|
+
class AwsDeployInitHostingSdkService {
|
|
12
|
+
async execute({ container, projectExtensions, project }) {
|
|
13
|
+
const hookExtensions = deployHooks.flatMap((hook)=>projectExtensions.extensionsByType(hook));
|
|
14
|
+
await registerSrcExtensions(container, hookExtensions, project);
|
|
15
|
+
container.registerDecorator(deployAppWithWatchedLambdaReplacement);
|
|
16
|
+
container.registerDecorator(deployAppClearWatchedLambdaFunctions);
|
|
17
|
+
container.registerDecorator(deployAppRefreshStackOutputCache);
|
|
18
|
+
container.registerDecorator(destroyAppClearStackOutputCache);
|
|
19
|
+
container.registerDecorator(deployAppWithHooks);
|
|
20
|
+
container.registerDecorator(getPulumiServiceWithDownloadInfo);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
const awsDeployInitHostingSdkService = createImplementation({
|
|
24
|
+
abstraction: InitHostingSdkService,
|
|
25
|
+
implementation: AwsDeployInitHostingSdkService,
|
|
26
|
+
dependencies: []
|
|
27
|
+
});
|
|
28
|
+
export { AwsDeployInitHostingSdkService, awsDeployInitHostingSdkService };
|
|
29
|
+
|
|
30
|
+
//# sourceMappingURL=AwsDeployInitHostingSdkService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/AwsDeployInitHostingSdkService/AwsDeployInitHostingSdkService.js","sources":["../../../src/services/AwsDeployInitHostingSdkService/AwsDeployInitHostingSdkService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { InitHostingSdkService } from \"@webiny/project/abstractions/index.js\";\nimport { registerSrcExtensions } from \"@webiny/project/utils/index.js\";\nimport { deployHooks } from \"@webiny/project-extensions-aws/extensions/hooks/deployHooks.js\";\nimport { deployAppClearWatchedLambdaFunctions } from \"~/decorators/DeployAppClearWatchedLambdaFunctions.js\";\nimport { deployAppRefreshStackOutputCache } from \"~/decorators/DeployAppRefreshStackOutputCache.js\";\nimport { deployAppWithHooks } from \"~/decorators/DeployAppWithHooks.js\";\nimport { deployAppWithWatchedLambdaReplacement } from \"~/decorators/DeployAppWithWatchedLambdaReplacement.js\";\nimport { destroyAppClearStackOutputCache } from \"~/decorators/DestroyAppClearStackOutputCache.js\";\nimport { getPulumiServiceWithDownloadInfo } from \"~/decorators/GetPulumiServiceWithDownloadInfo.js\";\n\n/**\n * The CLI side of deploying: the deploy hooks the project config names, and the decorators around\n * deploy, destroy and the Pulumi CLI download. Registered here, and only here, because the\n * container doesn't de-duplicate decorators: registering one twice wraps twice.\n */\nexport class AwsDeployInitHostingSdkService implements InitHostingSdkService.Interface {\n async execute({ container, projectExtensions, project }: InitHostingSdkService.Params) {\n const hookExtensions = deployHooks.flatMap(hook =>\n projectExtensions.extensionsByType(hook)\n );\n\n await registerSrcExtensions(container, hookExtensions, project);\n\n container.registerDecorator(deployAppWithWatchedLambdaReplacement);\n container.registerDecorator(deployAppClearWatchedLambdaFunctions);\n container.registerDecorator(deployAppRefreshStackOutputCache);\n container.registerDecorator(destroyAppClearStackOutputCache);\n container.registerDecorator(deployAppWithHooks);\n container.registerDecorator(getPulumiServiceWithDownloadInfo);\n }\n}\n\nexport const awsDeployInitHostingSdkService = createImplementation({\n abstraction: InitHostingSdkService,\n implementation: AwsDeployInitHostingSdkService,\n dependencies: []\n});\n"],"names":["AwsDeployInitHostingSdkService","container","projectExtensions","project","hookExtensions","deployHooks","hook","registerSrcExtensions","deployAppWithWatchedLambdaReplacement","deployAppClearWatchedLambdaFunctions","deployAppRefreshStackOutputCache","destroyAppClearStackOutputCache","deployAppWithHooks","getPulumiServiceWithDownloadInfo","awsDeployInitHostingSdkService","createImplementation","InitHostingSdkService"],"mappings":";;;;;;;;;;AAgBO,MAAMA;IACT,MAAM,QAAQ,EAAEC,SAAS,EAAEC,iBAAiB,EAAEC,OAAO,EAAgC,EAAE;QACnF,MAAMC,iBAAiBC,YAAY,OAAO,CAACC,CAAAA,OACvCJ,kBAAkB,gBAAgB,CAACI;QAGvC,MAAMC,sBAAsBN,WAAWG,gBAAgBD;QAEvDF,UAAU,iBAAiB,CAACO;QAC5BP,UAAU,iBAAiB,CAACQ;QAC5BR,UAAU,iBAAiB,CAACS;QAC5BT,UAAU,iBAAiB,CAACU;QAC5BV,UAAU,iBAAiB,CAACW;QAC5BX,UAAU,iBAAiB,CAACY;IAChC;AACJ;AAEO,MAAMC,iCAAiCC,qBAAqB;IAC/D,aAAaC;IACb,gBAAgBhB;IAChB,cAAc,EAAE;AACpB"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { InitHostingSdkService } from "@webiny/project/abstractions/index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Registers the Pulumi programs the project config names (`Core/Pulumi`, `Api/Pulumi`,
|
|
4
|
+
* `Admin/Pulumi`). Both the CLI and the Pulumi program's own SDK need these.
|
|
5
|
+
*/
|
|
6
|
+
export declare class AwsPulumiInitHostingSdkService implements InitHostingSdkService.Interface {
|
|
7
|
+
execute({ container, projectExtensions, project }: InitHostingSdkService.Params): Promise<void>;
|
|
8
|
+
}
|
|
9
|
+
export declare const awsPulumiInitHostingSdkService: import("@webiny/di").Implementation<typeof AwsPulumiInitHostingSdkService>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { InitHostingSdkService } from "@webiny/project/abstractions/index.js";
|
|
3
|
+
import { registerSrcExtensions } from "@webiny/project/utils/index.js";
|
|
4
|
+
import { CorePulumi } from "@webiny/project-extensions-aws/extensions/CorePulumi.js";
|
|
5
|
+
import { ApiPulumi } from "@webiny/project-extensions-aws/extensions/ApiPulumi.js";
|
|
6
|
+
import { AdminPulumi } from "@webiny/project-extensions-aws/extensions/AdminPulumi.js";
|
|
7
|
+
class AwsPulumiInitHostingSdkService {
|
|
8
|
+
async execute({ container, projectExtensions, project }) {
|
|
9
|
+
const pulumiExtensions = [
|
|
10
|
+
...projectExtensions.extensionsByType(CorePulumi),
|
|
11
|
+
...projectExtensions.extensionsByType(ApiPulumi),
|
|
12
|
+
...projectExtensions.extensionsByType(AdminPulumi)
|
|
13
|
+
];
|
|
14
|
+
await registerSrcExtensions(container, pulumiExtensions, project);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
const awsPulumiInitHostingSdkService = createImplementation({
|
|
18
|
+
abstraction: InitHostingSdkService,
|
|
19
|
+
implementation: AwsPulumiInitHostingSdkService,
|
|
20
|
+
dependencies: []
|
|
21
|
+
});
|
|
22
|
+
export { AwsPulumiInitHostingSdkService, awsPulumiInitHostingSdkService };
|
|
23
|
+
|
|
24
|
+
//# sourceMappingURL=AwsPulumiInitHostingSdkService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/AwsPulumiInitHostingSdkService/AwsPulumiInitHostingSdkService.js","sources":["../../../src/services/AwsPulumiInitHostingSdkService/AwsPulumiInitHostingSdkService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { InitHostingSdkService } from \"@webiny/project/abstractions/index.js\";\nimport { registerSrcExtensions } from \"@webiny/project/utils/index.js\";\nimport { CorePulumi } from \"@webiny/project-extensions-aws/extensions/CorePulumi.js\";\nimport { ApiPulumi } from \"@webiny/project-extensions-aws/extensions/ApiPulumi.js\";\nimport { AdminPulumi } from \"@webiny/project-extensions-aws/extensions/AdminPulumi.js\";\n\n/**\n * Registers the Pulumi programs the project config names (`Core/Pulumi`, `Api/Pulumi`,\n * `Admin/Pulumi`). Both the CLI and the Pulumi program's own SDK need these.\n */\nexport class AwsPulumiInitHostingSdkService implements InitHostingSdkService.Interface {\n async execute({ container, projectExtensions, project }: InitHostingSdkService.Params) {\n const pulumiExtensions = [\n ...projectExtensions.extensionsByType(CorePulumi),\n ...projectExtensions.extensionsByType(ApiPulumi),\n ...projectExtensions.extensionsByType(AdminPulumi)\n ];\n\n await registerSrcExtensions(container, pulumiExtensions, project);\n }\n}\n\nexport const awsPulumiInitHostingSdkService = createImplementation({\n abstraction: InitHostingSdkService,\n implementation: AwsPulumiInitHostingSdkService,\n dependencies: []\n});\n"],"names":["AwsPulumiInitHostingSdkService","container","projectExtensions","project","pulumiExtensions","CorePulumi","ApiPulumi","AdminPulumi","registerSrcExtensions","awsPulumiInitHostingSdkService","createImplementation","InitHostingSdkService"],"mappings":";;;;;;AAWO,MAAMA;IACT,MAAM,QAAQ,EAAEC,SAAS,EAAEC,iBAAiB,EAAEC,OAAO,EAAgC,EAAE;QACnF,MAAMC,mBAAmB;eAClBF,kBAAkB,gBAAgB,CAACG;eACnCH,kBAAkB,gBAAgB,CAACI;eACnCJ,kBAAkB,gBAAgB,CAACK;SACzC;QAED,MAAMC,sBAAsBP,WAAWG,kBAAkBD;IAC7D;AACJ;AAEO,MAAMM,iCAAiCC,qBAAqB;IAC/D,aAAaC;IACb,gBAAgBX;IAChB,cAAc,EAAE;AACpB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GetAppStackOutput } from "
|
|
1
|
+
import { GetAppStackOutput } from "../abstractions/features/GetAppStackOutput.js";
|
|
2
2
|
import { CoreStackOutputService as CoreStackOutputServiceAbstraction } from "@webiny/project-extensions-aws/abstractions/index.js";
|
|
3
3
|
export declare class DefaultCoreStackOutputServiceAbstraction implements CoreStackOutputServiceAbstraction.Interface {
|
|
4
4
|
private readonly getAppStackOutput;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GetAppStackOutput } from "
|
|
1
|
+
import { GetAppStackOutput } from "../abstractions/features/GetAppStackOutput.js";
|
|
2
2
|
import { CoreStackOutputService } from "@webiny/project-extensions-aws/abstractions/index.js";
|
|
3
3
|
class DefaultCoreStackOutputServiceAbstraction {
|
|
4
4
|
constructor(getAppStackOutput){
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"services/CoreStackOutputService.js","sources":["../../src/services/CoreStackOutputService.ts"],"sourcesContent":["import { GetAppStackOutput } from \"
|
|
1
|
+
{"version":3,"file":"services/CoreStackOutputService.js","sources":["../../src/services/CoreStackOutputService.ts"],"sourcesContent":["import { GetAppStackOutput } from \"~/abstractions/features/GetAppStackOutput.js\";\nimport { CoreStackOutputService as CoreStackOutputServiceAbstraction } from \"@webiny/project-extensions-aws/abstractions/index.js\";\n\nexport class DefaultCoreStackOutputServiceAbstraction\n implements CoreStackOutputServiceAbstraction.Interface\n{\n constructor(private readonly getAppStackOutput: GetAppStackOutput.Interface) {}\n\n async execute<\n TOutput extends CoreStackOutputServiceAbstraction.Output =\n CoreStackOutputServiceAbstraction.Output\n >(): Promise<TOutput | null> {\n return this.getAppStackOutput.execute<TOutput>(\"core\");\n }\n}\n\nexport const CoreStackOutputService = CoreStackOutputServiceAbstraction.createImplementation({\n implementation: DefaultCoreStackOutputServiceAbstraction,\n dependencies: [GetAppStackOutput]\n});\n"],"names":["DefaultCoreStackOutputServiceAbstraction","getAppStackOutput","CoreStackOutputService","CoreStackOutputServiceAbstraction","GetAppStackOutput"],"mappings":";;AAGO,MAAMA;IAGT,YAA6BC,iBAA8C,CAAE;aAAhDA,iBAAiB,GAAjBA;IAAiD;IAE9E,MAAM,UAGuB;QACzB,OAAO,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAU;IACnD;AACJ;AAEO,MAAMC,gDAAyBC,uBAAAA,oBAAsD,CAAC;IACzF,gBAAgBH;IAChB,cAAc;QAACI;KAAkB;AACrC"}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import { GetProjectService
|
|
1
|
+
import { GetProjectService } from "@webiny/project/abstractions/index.js";
|
|
2
|
+
import { ProjectSdkParamsService } from "@webiny/project/abstractions/index.js";
|
|
3
|
+
import { GetPulumiService } from "../../abstractions/services/GetPulumiService.js";
|
|
2
4
|
export declare class DefaultGetPulumiService implements GetPulumiService.Interface {
|
|
3
5
|
private readonly getProjectService;
|
|
4
6
|
private readonly projectSdkParamsService;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { createImplementation } from "@webiny/di";
|
|
2
|
-
import { GetProjectService,
|
|
2
|
+
import { GetProjectService, ProjectSdkParamsService } from "@webiny/project/abstractions/index.js";
|
|
3
|
+
import { GetPulumiService } from "../../abstractions/services/GetPulumiService.js";
|
|
3
4
|
import { WBY_PROJECT_SDK_CONTEXT, serializeProjectSdkContext } from "@webiny/project/utils/index.js";
|
|
4
5
|
class DefaultGetPulumiService {
|
|
5
6
|
constructor(getProjectService, projectSdkParamsService){
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"services/GetPulumiService/GetPulumiService.js","sources":["../../../src/services/GetPulumiService/GetPulumiService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport {\
|
|
1
|
+
{"version":3,"file":"services/GetPulumiService/GetPulumiService.js","sources":["../../../src/services/GetPulumiService/GetPulumiService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { GetProjectService } from \"@webiny/project/abstractions/index.js\";\nimport { ProjectSdkParamsService } from \"@webiny/project/abstractions/index.js\";\nimport { GetPulumiService } from \"~/abstractions/services/GetPulumiService.js\";\nimport {\n serializeProjectSdkContext,\n WBY_PROJECT_SDK_CONTEXT\n} from \"@webiny/project/utils/index.js\";\n\nexport class DefaultGetPulumiService implements GetPulumiService.Interface {\n constructor(\n private readonly getProjectService: GetProjectService.Interface,\n private readonly projectSdkParamsService: ProjectSdkParamsService.Interface\n ) {}\n\n async execute(params: GetPulumiService.Params = {}) {\n const project = this.getProjectService.execute();\n const { app, pulumiOptions = {} } = params;\n\n let cwd;\n if (app) {\n cwd = app.paths.workspaceFolder.toString();\n }\n\n const sdkParams = this.projectSdkParamsService.get();\n const contextEnv = {\n [WBY_PROJECT_SDK_CONTEXT]: serializeProjectSdkContext(sdkParams)\n };\n\n const mergedExeca = {\n ...pulumiOptions.execa,\n cwd,\n env: {\n ...pulumiOptions.execa?.env,\n ...contextEnv\n }\n };\n\n // Loaded here rather than at the top of the file. This service is registered for every\n // command, and the Pulumi SDK is only needed by the commands that run Pulumi.\n const { Pulumi } = await import(\"@webiny/pulumi-sdk\");\n\n return Pulumi.create({\n ...pulumiOptions,\n execa: mergedExeca,\n pulumiFolder: project.paths.dotWebinyFolder.toString()\n });\n }\n}\n\nexport const getPulumiService = createImplementation({\n abstraction: GetPulumiService,\n implementation: DefaultGetPulumiService,\n dependencies: [GetProjectService, ProjectSdkParamsService]\n});\n"],"names":["DefaultGetPulumiService","getProjectService","projectSdkParamsService","params","project","app","pulumiOptions","cwd","sdkParams","contextEnv","WBY_PROJECT_SDK_CONTEXT","serializeProjectSdkContext","mergedExeca","Pulumi","getPulumiService","createImplementation","GetPulumiService","GetProjectService","ProjectSdkParamsService"],"mappings":";;;;AASO,MAAMA;IACT,YACqBC,iBAA8C,EAC9CC,uBAA0D,CAC7E;aAFmBD,iBAAiB,GAAjBA;aACAC,uBAAuB,GAAvBA;IAClB;IAEH,MAAM,QAAQC,SAAkC,CAAC,CAAC,EAAE;QAChD,MAAMC,UAAU,IAAI,CAAC,iBAAiB,CAAC,OAAO;QAC9C,MAAM,EAAEC,GAAG,EAAEC,gBAAgB,CAAC,CAAC,EAAE,GAAGH;QAEpC,IAAII;QACJ,IAAIF,KACAE,MAAMF,IAAI,KAAK,CAAC,eAAe,CAAC,QAAQ;QAG5C,MAAMG,YAAY,IAAI,CAAC,uBAAuB,CAAC,GAAG;QAClD,MAAMC,aAAa;YACf,CAACC,wBAAwB,EAAEC,2BAA2BH;QAC1D;QAEA,MAAMI,cAAc;YAChB,GAAGN,cAAc,KAAK;YACtBC;YACA,KAAK;gBACD,GAAGD,cAAc,KAAK,EAAE,GAAG;gBAC3B,GAAGG,UAAU;YACjB;QACJ;QAIA,MAAM,EAAEI,MAAM,EAAE,GAAG,MAAM,MAAM,CAAC;QAEhC,OAAOA,OAAO,MAAM,CAAC;YACjB,GAAGP,aAAa;YAChB,OAAOM;YACP,cAAcR,QAAQ,KAAK,CAAC,eAAe,CAAC,QAAQ;QACxD;IACJ;AACJ;AAEO,MAAMU,mBAAmBC,qBAAqB;IACjD,aAAaC;IACb,gBAAgBhB;IAChB,cAAc;QAACiB;QAAmBC;KAAwB;AAC9D"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { GetPulumiVersionService } from "../../abstractions/services/GetPulumiVersionService.js";
|
|
2
|
+
export declare class DefaultGetPulumiVersion implements GetPulumiVersionService.Interface {
|
|
3
|
+
execute(): import("~/abstractions/services/GetPulumiVersionService.js").IGetPulumiVersionServiceResult;
|
|
4
|
+
}
|
|
5
|
+
export declare const getPulumiVersionService: import("@webiny/di").Implementation<typeof DefaultGetPulumiVersion>;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { GetPulumiVersionService } from "../../abstractions/services/GetPulumiVersionService.js";
|
|
3
|
+
import { execaSync } from "execa";
|
|
4
|
+
class DefaultGetPulumiVersion {
|
|
5
|
+
execute() {
|
|
6
|
+
const result = [
|
|
7
|
+
"",
|
|
8
|
+
""
|
|
9
|
+
];
|
|
10
|
+
try {
|
|
11
|
+
{
|
|
12
|
+
const { stdout } = execaSync("yarn", [
|
|
13
|
+
"info",
|
|
14
|
+
"@pulumi/pulumi",
|
|
15
|
+
"-A",
|
|
16
|
+
"-R",
|
|
17
|
+
"--name-only",
|
|
18
|
+
"--json"
|
|
19
|
+
]);
|
|
20
|
+
const match = stdout.match(/npm:(.*?)"/);
|
|
21
|
+
if (match) result[0] = match[1];
|
|
22
|
+
}
|
|
23
|
+
{
|
|
24
|
+
const { stdout } = execaSync("yarn", [
|
|
25
|
+
"info",
|
|
26
|
+
"@pulumi/aws",
|
|
27
|
+
"-A",
|
|
28
|
+
"-R",
|
|
29
|
+
"--name-only",
|
|
30
|
+
"--json"
|
|
31
|
+
]);
|
|
32
|
+
const match = stdout.match(/npm:(.*?)"/);
|
|
33
|
+
if (match) result[1] = match[1];
|
|
34
|
+
}
|
|
35
|
+
} catch {}
|
|
36
|
+
return result;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
const getPulumiVersionService = createImplementation({
|
|
40
|
+
abstraction: GetPulumiVersionService,
|
|
41
|
+
implementation: DefaultGetPulumiVersion,
|
|
42
|
+
dependencies: []
|
|
43
|
+
});
|
|
44
|
+
export { DefaultGetPulumiVersion, getPulumiVersionService };
|
|
45
|
+
|
|
46
|
+
//# sourceMappingURL=GetPulumiVersionService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/GetPulumiVersionService/GetPulumiVersionService.js","sources":["../../../src/services/GetPulumiVersionService/GetPulumiVersionService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { GetPulumiVersionService } from \"~/abstractions/services/GetPulumiVersionService.js\";\nimport { execaSync } from \"execa\";\n\nexport class DefaultGetPulumiVersion implements GetPulumiVersionService.Interface {\n execute() {\n const result: GetPulumiVersionService.Result = [\"\", \"\"];\n\n try {\n {\n const { stdout } = execaSync(\"yarn\", [\n \"info\",\n \"@pulumi/pulumi\",\n \"-A\",\n \"-R\",\n \"--name-only\",\n \"--json\"\n ]);\n\n const match = stdout.match(/npm:(.*?)\"/);\n if (match) {\n result[0] = match[1];\n }\n }\n\n {\n const { stdout } = execaSync(\"yarn\", [\n \"info\",\n \"@pulumi/aws\",\n \"-A\",\n \"-R\",\n \"--name-only\",\n \"--json\"\n ]);\n\n const match = stdout.match(/npm:(.*?)\"/);\n if (match) {\n result[1] = match[1];\n }\n }\n } catch {\n // Do nothing.\n }\n\n return result;\n }\n}\n\nexport const getPulumiVersionService = createImplementation({\n abstraction: GetPulumiVersionService,\n implementation: DefaultGetPulumiVersion,\n dependencies: []\n});\n"],"names":["DefaultGetPulumiVersion","result","stdout","execaSync","match","getPulumiVersionService","createImplementation","GetPulumiVersionService"],"mappings":";;;AAIO,MAAMA;IACT,UAAU;QACN,MAAMC,SAAyC;YAAC;YAAI;SAAG;QAEvD,IAAI;YACA;gBACI,MAAM,EAAEC,MAAM,EAAE,GAAGC,UAAU,QAAQ;oBACjC;oBACA;oBACA;oBACA;oBACA;oBACA;iBACH;gBAED,MAAMC,QAAQF,OAAO,KAAK,CAAC;gBAC3B,IAAIE,OACAH,MAAM,CAAC,EAAE,GAAGG,KAAK,CAAC,EAAE;YAE5B;YAEA;gBACI,MAAM,EAAEF,MAAM,EAAE,GAAGC,UAAU,QAAQ;oBACjC;oBACA;oBACA;oBACA;oBACA;oBACA;iBACH;gBAED,MAAMC,QAAQF,OAAO,KAAK,CAAC;gBAC3B,IAAIE,OACAH,MAAM,CAAC,EAAE,GAAGG,KAAK,CAAC,EAAE;YAE5B;QACJ,EAAE,OAAM,CAER;QAEA,OAAOH;IACX;AACJ;AAEO,MAAMI,0BAA0BC,qBAAqB;IACxD,aAAaC;IACb,gBAAgBP;IAChB,cAAc,EAAE;AACpB"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { IsRemotePulumiBackendService } from "../../abstractions/services/IsRemotePulumiBackendService.js";
|
|
2
|
+
/**
|
|
3
|
+
* Service to check if a remote Pulumi backend is configured via environment variables.
|
|
4
|
+
*
|
|
5
|
+
* Checks for the following environment variables:
|
|
6
|
+
* - WEBINY_CLI_PULUMI_BACKEND (canonical)
|
|
7
|
+
* - WEBINY_CLI_PULUMI_BACKEND_URL
|
|
8
|
+
* - WEBINY_PULUMI_BACKEND (legacy, kept for backwards compatibility)
|
|
9
|
+
* - PULUMI_LOGIN (fallback for standard Pulumi configuration)
|
|
10
|
+
*/
|
|
11
|
+
export declare class DefaultIsRemotePulumiBackendService implements IsRemotePulumiBackendService.Interface {
|
|
12
|
+
execute(): boolean;
|
|
13
|
+
}
|
|
14
|
+
export declare const isRemotePulumiBackendService: import("@webiny/di").Implementation<typeof DefaultIsRemotePulumiBackendService>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { IsRemotePulumiBackendService } from "../../abstractions/services/IsRemotePulumiBackendService.js";
|
|
3
|
+
class DefaultIsRemotePulumiBackendService {
|
|
4
|
+
execute() {
|
|
5
|
+
return !!(process.env.WEBINY_CLI_PULUMI_BACKEND || process.env.WEBINY_CLI_PULUMI_BACKEND_URL || process.env.WEBINY_PULUMI_BACKEND || process.env.PULUMI_LOGIN);
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
const isRemotePulumiBackendService = createImplementation({
|
|
9
|
+
abstraction: IsRemotePulumiBackendService,
|
|
10
|
+
implementation: DefaultIsRemotePulumiBackendService,
|
|
11
|
+
dependencies: []
|
|
12
|
+
});
|
|
13
|
+
export { DefaultIsRemotePulumiBackendService, isRemotePulumiBackendService };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=IsRemotePulumiBackendService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.js","sources":["../../../src/services/IsRemotePulumiBackendService/IsRemotePulumiBackendService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { IsRemotePulumiBackendService } from \"~/abstractions/services/IsRemotePulumiBackendService.js\";\n\n/**\n * Service to check if a remote Pulumi backend is configured via environment variables.\n *\n * Checks for the following environment variables:\n * - WEBINY_CLI_PULUMI_BACKEND (canonical)\n * - WEBINY_CLI_PULUMI_BACKEND_URL\n * - WEBINY_PULUMI_BACKEND (legacy, kept for backwards compatibility)\n * - PULUMI_LOGIN (fallback for standard Pulumi configuration)\n */\nexport class DefaultIsRemotePulumiBackendService implements IsRemotePulumiBackendService.Interface {\n execute(): boolean {\n return !!(\n process.env.WEBINY_CLI_PULUMI_BACKEND ||\n process.env.WEBINY_CLI_PULUMI_BACKEND_URL ||\n process.env.WEBINY_PULUMI_BACKEND ||\n process.env.PULUMI_LOGIN\n );\n }\n}\n\nexport const isRemotePulumiBackendService = createImplementation({\n abstraction: IsRemotePulumiBackendService,\n implementation: DefaultIsRemotePulumiBackendService,\n dependencies: []\n});\n"],"names":["DefaultIsRemotePulumiBackendService","process","isRemotePulumiBackendService","createImplementation","IsRemotePulumiBackendService"],"mappings":";;AAYO,MAAMA;IACT,UAAmB;QACf,OAAO,CAAC,CACJC,CAAAA,QAAQ,GAAG,CAAC,yBAAyB,IACrCA,QAAQ,GAAG,CAAC,6BAA6B,IACzCA,QAAQ,GAAG,CAAC,qBAAqB,IACjCA,QAAQ,GAAG,CAAC,YAAW;IAE/B;AACJ;AAEO,MAAMC,+BAA+BC,qBAAqB;IAC7D,aAAaC;IACb,gBAAgBJ;IAChB,cAAc,EAAE;AACpB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./IsRemotePulumiBackendService.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./IsRemotePulumiBackendService.js";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ListAppLambdaFunctionsService } from "../../abstractions/services/ListAppLambdaFunctionsService.js";
|
|
2
|
+
import { PulumiExportService } from "../../abstractions/services/PulumiExportService.js";
|
|
3
|
+
import { LoggerService } from "@webiny/project/abstractions/index.js";
|
|
4
|
+
import { type IAppModel } from "@webiny/project/abstractions/models/index.js";
|
|
5
|
+
export declare class DefaultListAppLambdaFunctionsService implements ListAppLambdaFunctionsService.Interface {
|
|
6
|
+
private pulumiExportService;
|
|
7
|
+
private loggerService;
|
|
8
|
+
constructor(pulumiExportService: PulumiExportService.Interface, loggerService: LoggerService.Interface);
|
|
9
|
+
execute(app: IAppModel, params?: ListAppLambdaFunctionsService.Params): Promise<{
|
|
10
|
+
list: {
|
|
11
|
+
name: string;
|
|
12
|
+
path: string;
|
|
13
|
+
}[];
|
|
14
|
+
meta: {
|
|
15
|
+
count: number;
|
|
16
|
+
totalCount: number;
|
|
17
|
+
};
|
|
18
|
+
}>;
|
|
19
|
+
}
|
|
20
|
+
export declare const listAppLambdaFunctionsService: import("@webiny/di").Implementation<typeof DefaultListAppLambdaFunctionsService>;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { ListAppLambdaFunctionsService } from "../../abstractions/services/ListAppLambdaFunctionsService.js";
|
|
3
|
+
import { PulumiExportService } from "../../abstractions/services/PulumiExportService.js";
|
|
4
|
+
import { LoggerService } from "@webiny/project/abstractions/index.js";
|
|
5
|
+
import path from "path";
|
|
6
|
+
import { minimatch } from "minimatch";
|
|
7
|
+
class DefaultListAppLambdaFunctionsService {
|
|
8
|
+
constructor(pulumiExportService, loggerService){
|
|
9
|
+
this.pulumiExportService = pulumiExportService;
|
|
10
|
+
this.loggerService = loggerService;
|
|
11
|
+
}
|
|
12
|
+
async execute(app, params) {
|
|
13
|
+
const stackExport = await this.pulumiExportService.execute(app);
|
|
14
|
+
if (!stackExport) return {
|
|
15
|
+
list: [],
|
|
16
|
+
meta: {
|
|
17
|
+
count: 0,
|
|
18
|
+
totalCount: 0
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const resources = stackExport.deployment?.resources ?? [];
|
|
22
|
+
const allFunctionsList = resources.filter((r)=>"aws:lambda/function:Function" === r.type).filter((resource)=>{
|
|
23
|
+
const isAuthorizerFunction = resource.inputs.name.includes("watch-command-iot-authorizer");
|
|
24
|
+
return !isAuthorizerFunction;
|
|
25
|
+
});
|
|
26
|
+
let filteredFunctionsList = allFunctionsList.filter((resource)=>"." in resource.inputs.code.assets).map((resource)=>{
|
|
27
|
+
const fnName = resource.inputs.name;
|
|
28
|
+
const handlerBuildFolderPath = resource.inputs.code.assets["."].path;
|
|
29
|
+
const handlerPath = path.join(handlerBuildFolderPath, "handler.mjs");
|
|
30
|
+
return {
|
|
31
|
+
name: fnName,
|
|
32
|
+
path: handlerPath
|
|
33
|
+
};
|
|
34
|
+
});
|
|
35
|
+
if (params?.whitelist?.length) {
|
|
36
|
+
const functionNamesToMatch = Array.isArray(params.whitelist) ? params.whitelist : [
|
|
37
|
+
params.whitelist
|
|
38
|
+
];
|
|
39
|
+
filteredFunctionsList = filteredFunctionsList.filter((fn)=>functionNamesToMatch.some((pattern)=>{
|
|
40
|
+
if (pattern.includes("*")) return minimatch(fn.name, pattern);
|
|
41
|
+
return fn.name.includes(pattern);
|
|
42
|
+
}));
|
|
43
|
+
} else if ("api" === app.name) filteredFunctionsList = filteredFunctionsList.filter((fn)=>fn.name.includes("graphql"));
|
|
44
|
+
return {
|
|
45
|
+
list: filteredFunctionsList,
|
|
46
|
+
meta: {
|
|
47
|
+
count: filteredFunctionsList.length,
|
|
48
|
+
totalCount: allFunctionsList.length
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
const listAppLambdaFunctionsService = createImplementation({
|
|
54
|
+
abstraction: ListAppLambdaFunctionsService,
|
|
55
|
+
implementation: DefaultListAppLambdaFunctionsService,
|
|
56
|
+
dependencies: [
|
|
57
|
+
PulumiExportService,
|
|
58
|
+
LoggerService
|
|
59
|
+
]
|
|
60
|
+
});
|
|
61
|
+
export { DefaultListAppLambdaFunctionsService, listAppLambdaFunctionsService };
|
|
62
|
+
|
|
63
|
+
//# sourceMappingURL=ListAppLambdaFunctionsService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.js","sources":["../../../src/services/ListAppLambdaFunctionsService/ListAppLambdaFunctionsService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { ListAppLambdaFunctionsService } from \"~/abstractions/services/ListAppLambdaFunctionsService.js\";\nimport { PulumiExportService } from \"~/abstractions/services/PulumiExportService.js\";\nimport { LoggerService } from \"@webiny/project/abstractions/index.js\";\nimport { type IAppModel } from \"@webiny/project/abstractions/models/index.js\";\nimport path from \"path\";\nimport { minimatch } from \"minimatch\";\n\ninterface ExpectedStackExport {\n deployment: {\n resources: Array<{\n type: string;\n inputs: {\n name: string;\n code: {\n assets: Record<string, { path: string }>;\n };\n };\n }>;\n };\n}\n\nexport class DefaultListAppLambdaFunctionsService\n implements ListAppLambdaFunctionsService.Interface\n{\n constructor(\n private pulumiExportService: PulumiExportService.Interface,\n private loggerService: LoggerService.Interface\n ) {}\n\n async execute(app: IAppModel, params?: ListAppLambdaFunctionsService.Params) {\n const stackExport = await this.pulumiExportService.execute<ExpectedStackExport>(app);\n\n if (!stackExport) {\n // If no stack export is found, return an empty array. This is a valid scenario.\n // For example, watching the Admin app locally, but not deploying it.\n return {\n list: [],\n meta: {\n count: 0,\n totalCount: 0\n }\n };\n }\n\n // If an app is not deployed, resources will not exist.\n const resources = stackExport.deployment?.resources ?? [];\n\n const allFunctionsList = resources\n .filter(r => r.type === \"aws:lambda/function:Function\")\n // We don't need to watch the authorizer function.\n .filter(resource => {\n const isAuthorizerFunction = resource.inputs.name.includes(\n \"watch-command-iot-authorizer\"\n );\n return !isAuthorizerFunction;\n });\n\n let filteredFunctionsList = allFunctionsList\n // First, this filter ensures that Lambda@Edge functions are excluded. Second,\n // it also ensures a function is filtered out if a `pulumi refresh` was called.\n // This is because, when called, the paths in Pulumi state file disappear, and\n // we can't determine the path to the handler. Probably needs revisiting. 🤦♂️\n .filter(resource => {\n return \".\" in resource.inputs.code.assets;\n })\n .map(resource => {\n const fnName = resource.inputs.name;\n const handlerBuildFolderPath = resource.inputs.code.assets[\".\"].path;\n\n const handlerPath = path.join(handlerBuildFolderPath, \"handler.mjs\");\n return {\n name: fnName,\n path: handlerPath\n };\n });\n\n if (params?.whitelist?.length) {\n const functionNamesToMatch = Array.isArray(params.whitelist)\n ? params.whitelist\n : [params.whitelist];\n\n // `functionNamesToWatch` is an array of glob patterns, which denote which functions to watch.\n filteredFunctionsList = filteredFunctionsList.filter(fn => {\n return functionNamesToMatch.some(pattern => {\n if (pattern.includes(\"*\")) {\n return minimatch(fn.name, pattern);\n }\n\n return fn.name.includes(pattern);\n });\n });\n } else {\n // We've hardcoded this filtering here just because of lack of time.\n // With v5, these \"presets\" were located within `webiny.application.ts` files.\n if (app.name === \"api\") {\n filteredFunctionsList = filteredFunctionsList.filter(fn => {\n return fn.name.includes(\"graphql\");\n });\n }\n }\n\n return {\n list: filteredFunctionsList,\n meta: { count: filteredFunctionsList.length, totalCount: allFunctionsList.length }\n };\n }\n}\n\nexport const listAppLambdaFunctionsService = createImplementation({\n abstraction: ListAppLambdaFunctionsService,\n implementation: DefaultListAppLambdaFunctionsService,\n dependencies: [PulumiExportService, LoggerService]\n});\n"],"names":["DefaultListAppLambdaFunctionsService","pulumiExportService","loggerService","app","params","stackExport","resources","allFunctionsList","r","resource","isAuthorizerFunction","filteredFunctionsList","fnName","handlerBuildFolderPath","handlerPath","path","functionNamesToMatch","Array","fn","pattern","minimatch","listAppLambdaFunctionsService","createImplementation","ListAppLambdaFunctionsService","PulumiExportService","LoggerService"],"mappings":";;;;;;AAsBO,MAAMA;IAGT,YACYC,mBAAkD,EAClDC,aAAsC,CAChD;aAFUD,mBAAmB,GAAnBA;aACAC,aAAa,GAAbA;IACT;IAEH,MAAM,QAAQC,GAAc,EAAEC,MAA6C,EAAE;QACzE,MAAMC,cAAc,MAAM,IAAI,CAAC,mBAAmB,CAAC,OAAO,CAAsBF;QAEhF,IAAI,CAACE,aAGD,OAAO;YACH,MAAM,EAAE;YACR,MAAM;gBACF,OAAO;gBACP,YAAY;YAChB;QACJ;QAIJ,MAAMC,YAAYD,YAAY,UAAU,EAAE,aAAa,EAAE;QAEzD,MAAME,mBAAmBD,UACpB,MAAM,CAACE,CAAAA,IAAKA,AAAW,mCAAXA,EAAE,IAAI,EAElB,MAAM,CAACC,CAAAA;YACJ,MAAMC,uBAAuBD,SAAS,MAAM,CAAC,IAAI,CAAC,QAAQ,CACtD;YAEJ,OAAO,CAACC;QACZ;QAEJ,IAAIC,wBAAwBJ,iBAKvB,MAAM,CAACE,CAAAA,WACG,OAAOA,SAAS,MAAM,CAAC,IAAI,CAAC,MAAM,EAE5C,GAAG,CAACA,CAAAA;YACD,MAAMG,SAASH,SAAS,MAAM,CAAC,IAAI;YACnC,MAAMI,yBAAyBJ,SAAS,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI;YAEpE,MAAMK,cAAcC,KAAK,IAAI,CAACF,wBAAwB;YACtD,OAAO;gBACH,MAAMD;gBACN,MAAME;YACV;QACJ;QAEJ,IAAIV,QAAQ,WAAW,QAAQ;YAC3B,MAAMY,uBAAuBC,MAAM,OAAO,CAACb,OAAO,SAAS,IACrDA,OAAO,SAAS,GAChB;gBAACA,OAAO,SAAS;aAAC;YAGxBO,wBAAwBA,sBAAsB,MAAM,CAACO,CAAAA,KAC1CF,qBAAqB,IAAI,CAACG,CAAAA;oBAC7B,IAAIA,QAAQ,QAAQ,CAAC,MACjB,OAAOC,UAAUF,GAAG,IAAI,EAAEC;oBAG9B,OAAOD,GAAG,IAAI,CAAC,QAAQ,CAACC;gBAC5B;QAER,OAGI,IAAIhB,AAAa,UAAbA,IAAI,IAAI,EACRQ,wBAAwBA,sBAAsB,MAAM,CAACO,CAAAA,KAC1CA,GAAG,IAAI,CAAC,QAAQ,CAAC;QAKpC,OAAO;YACH,MAAMP;YACN,MAAM;gBAAE,OAAOA,sBAAsB,MAAM;gBAAE,YAAYJ,iBAAiB,MAAM;YAAC;QACrF;IACJ;AACJ;AAEO,MAAMc,gCAAgCC,qBAAqB;IAC9D,aAAaC;IACb,gBAAgBvB;IAChB,cAAc;QAACwB;QAAqBC;KAAc;AACtD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./ListAppLambdaFunctionsService.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./ListAppLambdaFunctionsService.js";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { GetProjectService } from "@webiny/project/abstractions/index.js";
|
|
2
|
+
import { ListDeployedEnvironmentsService } from "../../abstractions/services/ListDeployedEnvironmentsService.js";
|
|
3
|
+
export declare class DefaultListDeployedEnvironmentsService implements ListDeployedEnvironmentsService.Interface {
|
|
4
|
+
private getProjectService;
|
|
5
|
+
constructor(getProjectService: GetProjectService.Interface);
|
|
6
|
+
execute(): Promise<import("@webiny/project/utils/getStackName").IStack[]>;
|
|
7
|
+
}
|
|
8
|
+
export declare const listDeployedEnvironmentsService: import("@webiny/di").Implementation<typeof DefaultListDeployedEnvironmentsService>;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { GetProjectService } from "@webiny/project/abstractions/index.js";
|
|
3
|
+
import { ListDeployedEnvironmentsService } from "../../abstractions/services/ListDeployedEnvironmentsService.js";
|
|
4
|
+
import path from "path";
|
|
5
|
+
import fast_glob from "fast-glob";
|
|
6
|
+
import { splitStackName } from "@webiny/project/utils/index.js";
|
|
7
|
+
const STACK_JSONS_GLOB = ".pulumi/**/apps/core/.pulumi/stacks/**/*.json";
|
|
8
|
+
class DefaultListDeployedEnvironmentsService {
|
|
9
|
+
constructor(getProjectService){
|
|
10
|
+
this.getProjectService = getProjectService;
|
|
11
|
+
}
|
|
12
|
+
async execute() {
|
|
13
|
+
const project = this.getProjectService.execute();
|
|
14
|
+
const pulumiCoreStackFilesPaths = fast_glob.sync(STACK_JSONS_GLOB, {
|
|
15
|
+
cwd: project.paths.rootFolder.toString(),
|
|
16
|
+
onlyFiles: true,
|
|
17
|
+
dot: true
|
|
18
|
+
});
|
|
19
|
+
return pulumiCoreStackFilesPaths.map((current)=>splitStackName(path.basename(current, ".json")));
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
const listDeployedEnvironmentsService = createImplementation({
|
|
23
|
+
abstraction: ListDeployedEnvironmentsService,
|
|
24
|
+
implementation: DefaultListDeployedEnvironmentsService,
|
|
25
|
+
dependencies: [
|
|
26
|
+
GetProjectService
|
|
27
|
+
]
|
|
28
|
+
});
|
|
29
|
+
export { DefaultListDeployedEnvironmentsService, listDeployedEnvironmentsService };
|
|
30
|
+
|
|
31
|
+
//# sourceMappingURL=ListDeployedEnvironmentsService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.js","sources":["../../../src/services/ListDeployedEnvironmentsService/ListDeployedEnvironmentsService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { GetProjectService } from \"@webiny/project/abstractions/index.js\";\nimport { ListDeployedEnvironmentsService } from \"~/abstractions/services/ListDeployedEnvironmentsService.js\";\nimport path from \"path\";\nimport glob from \"fast-glob\";\nimport { splitStackName } from \"@webiny/project/utils/index.js\";\n\nconst STACK_JSONS_GLOB = \".pulumi/**/apps/core/.pulumi/stacks/**/*.json\";\n\nexport class DefaultListDeployedEnvironmentsService\n implements ListDeployedEnvironmentsService.Interface\n{\n constructor(private getProjectService: GetProjectService.Interface) {}\n\n async execute() {\n const project = this.getProjectService.execute();\n\n // We just get stack files for deployed Core application. That's enough\n // to determine into which environments the user has deployed their project.\n const pulumiCoreStackFilesPaths = glob.sync(STACK_JSONS_GLOB, {\n cwd: project.paths.rootFolder.toString(),\n onlyFiles: true,\n dot: true\n });\n\n return pulumiCoreStackFilesPaths.map(current => {\n return splitStackName(path.basename(current, \".json\"));\n });\n }\n}\n\nexport const listDeployedEnvironmentsService = createImplementation({\n abstraction: ListDeployedEnvironmentsService,\n implementation: DefaultListDeployedEnvironmentsService,\n dependencies: [GetProjectService]\n});\n"],"names":["STACK_JSONS_GLOB","DefaultListDeployedEnvironmentsService","getProjectService","project","pulumiCoreStackFilesPaths","glob","current","splitStackName","path","listDeployedEnvironmentsService","createImplementation","ListDeployedEnvironmentsService","GetProjectService"],"mappings":";;;;;;AAOA,MAAMA,mBAAmB;AAElB,MAAMC;IAGT,YAAoBC,iBAA8C,CAAE;aAAhDA,iBAAiB,GAAjBA;IAAiD;IAErE,MAAM,UAAU;QACZ,MAAMC,UAAU,IAAI,CAAC,iBAAiB,CAAC,OAAO;QAI9C,MAAMC,4BAA4BC,UAAAA,IAAS,CAACL,kBAAkB;YAC1D,KAAKG,QAAQ,KAAK,CAAC,UAAU,CAAC,QAAQ;YACtC,WAAW;YACX,KAAK;QACT;QAEA,OAAOC,0BAA0B,GAAG,CAACE,CAAAA,UAC1BC,eAAeC,KAAK,QAAQ,CAACF,SAAS;IAErD;AACJ;AAEO,MAAMG,kCAAkCC,qBAAqB;IAChE,aAAaC;IACb,gBAAgBV;IAChB,cAAc;QAACW;KAAkB;AACrC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./ListDeployedEnvironmentsService.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./ListDeployedEnvironmentsService.js";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { GetPulumiService } from "../../abstractions/services/GetPulumiService.js";
|
|
2
|
+
import { LoggerService } from "@webiny/project/abstractions/index.js";
|
|
3
|
+
import { PulumiExportService } from "../../abstractions/services/PulumiExportService.js";
|
|
4
|
+
import { PulumiSelectStackService } from "../../abstractions/services/PulumiSelectStackService.js";
|
|
5
|
+
import { type IAppModel } from "@webiny/project/abstractions/models/index.js";
|
|
6
|
+
export declare class DefaultPulumiExportService implements PulumiExportService.Interface {
|
|
7
|
+
private getPulumiService;
|
|
8
|
+
private pulumiSelectStackService;
|
|
9
|
+
private loggerService;
|
|
10
|
+
constructor(getPulumiService: GetPulumiService.Interface, pulumiSelectStackService: PulumiSelectStackService.Interface, loggerService: LoggerService.Interface);
|
|
11
|
+
execute(app: IAppModel): Promise<any>;
|
|
12
|
+
}
|
|
13
|
+
export declare const pulumiExportService: import("@webiny/di").Implementation<typeof DefaultPulumiExportService>;
|
|
14
|
+
/** @deprecated Use pulumiExportService instead */
|
|
15
|
+
export declare const pulumiGetStackExportService: import("@webiny/di").Implementation<typeof DefaultPulumiExportService>;
|
|
16
|
+
export declare const DefaultPulumiGetStackExportService: typeof DefaultPulumiExportService;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { GetPulumiService } from "../../abstractions/services/GetPulumiService.js";
|
|
3
|
+
import { LoggerService } from "@webiny/project/abstractions/index.js";
|
|
4
|
+
import { PulumiExportService } from "../../abstractions/services/PulumiExportService.js";
|
|
5
|
+
import { PulumiSelectStackService } from "../../abstractions/services/PulumiSelectStackService.js";
|
|
6
|
+
import { createEnvConfiguration } from "@webiny/project/utils/env/index.js";
|
|
7
|
+
import { withPulumiConfigPassphrase } from "../../utils/withPulumiConfigPassphrase.js";
|
|
8
|
+
class DefaultPulumiExportService {
|
|
9
|
+
constructor(getPulumiService, pulumiSelectStackService, loggerService){
|
|
10
|
+
this.getPulumiService = getPulumiService;
|
|
11
|
+
this.pulumiSelectStackService = pulumiSelectStackService;
|
|
12
|
+
this.loggerService = loggerService;
|
|
13
|
+
}
|
|
14
|
+
async execute(app) {
|
|
15
|
+
const pulumi = await this.getPulumiService.execute({
|
|
16
|
+
app
|
|
17
|
+
});
|
|
18
|
+
await this.pulumiSelectStackService.execute(app);
|
|
19
|
+
const stackOutputString = await pulumi.run({
|
|
20
|
+
command: [
|
|
21
|
+
"stack",
|
|
22
|
+
"export"
|
|
23
|
+
],
|
|
24
|
+
args: {},
|
|
25
|
+
execa: {
|
|
26
|
+
env: createEnvConfiguration({
|
|
27
|
+
configurations: [
|
|
28
|
+
withPulumiConfigPassphrase()
|
|
29
|
+
]
|
|
30
|
+
})
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
try {
|
|
34
|
+
return JSON.parse(stackOutputString.stdout);
|
|
35
|
+
} catch {
|
|
36
|
+
this.loggerService.error("Could not parse stack export as JSON.", stackOutputString.stdout, app);
|
|
37
|
+
return null;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
const pulumiExportService = createImplementation({
|
|
42
|
+
abstraction: PulumiExportService,
|
|
43
|
+
implementation: DefaultPulumiExportService,
|
|
44
|
+
dependencies: [
|
|
45
|
+
GetPulumiService,
|
|
46
|
+
PulumiSelectStackService,
|
|
47
|
+
LoggerService
|
|
48
|
+
]
|
|
49
|
+
});
|
|
50
|
+
const pulumiGetStackExportService = pulumiExportService;
|
|
51
|
+
const DefaultPulumiGetStackExportService = DefaultPulumiExportService;
|
|
52
|
+
export { DefaultPulumiExportService, DefaultPulumiGetStackExportService, pulumiExportService, pulumiGetStackExportService };
|
|
53
|
+
|
|
54
|
+
//# sourceMappingURL=PulumiExportService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/PulumiExportService/PulumiExportService.js","sources":["../../../src/services/PulumiExportService/PulumiExportService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { GetPulumiService } from \"~/abstractions/services/GetPulumiService.js\";\nimport { LoggerService } from \"@webiny/project/abstractions/index.js\";\nimport { PulumiExportService } from \"~/abstractions/services/PulumiExportService.js\";\nimport { PulumiSelectStackService } from \"~/abstractions/services/PulumiSelectStackService.js\";\nimport { type IAppModel } from \"@webiny/project/abstractions/models/index.js\";\nimport { createEnvConfiguration } from \"@webiny/project/utils/env/index.js\";\nimport { withPulumiConfigPassphrase } from \"~/utils/withPulumiConfigPassphrase.js\";\n\nexport class DefaultPulumiExportService implements PulumiExportService.Interface {\n constructor(\n private getPulumiService: GetPulumiService.Interface,\n private pulumiSelectStackService: PulumiSelectStackService.Interface,\n private loggerService: LoggerService.Interface\n ) {}\n\n async execute(app: IAppModel) {\n const pulumi = await this.getPulumiService.execute({ app });\n\n await this.pulumiSelectStackService.execute(app);\n\n const stackOutputString = await pulumi.run({\n command: [\"stack\", \"export\"],\n args: {},\n execa: {\n env: createEnvConfiguration({\n configurations: [withPulumiConfigPassphrase()]\n })\n }\n });\n\n try {\n return JSON.parse(stackOutputString.stdout as string);\n } catch {\n this.loggerService.error(\n \"Could not parse stack export as JSON.\",\n stackOutputString.stdout,\n app\n );\n return null;\n }\n }\n}\n\nexport const pulumiExportService = createImplementation({\n abstraction: PulumiExportService,\n implementation: DefaultPulumiExportService,\n dependencies: [GetPulumiService, PulumiSelectStackService, LoggerService]\n});\n\n// Backwards compatibility\n/** @deprecated Use pulumiExportService instead */\nexport const pulumiGetStackExportService = pulumiExportService;\nexport const DefaultPulumiGetStackExportService = DefaultPulumiExportService;\n"],"names":["DefaultPulumiExportService","getPulumiService","pulumiSelectStackService","loggerService","app","pulumi","stackOutputString","createEnvConfiguration","withPulumiConfigPassphrase","JSON","pulumiExportService","createImplementation","PulumiExportService","GetPulumiService","PulumiSelectStackService","LoggerService","pulumiGetStackExportService","DefaultPulumiGetStackExportService"],"mappings":";;;;;;;AASO,MAAMA;IACT,YACYC,gBAA4C,EAC5CC,wBAA4D,EAC5DC,aAAsC,CAChD;aAHUF,gBAAgB,GAAhBA;aACAC,wBAAwB,GAAxBA;aACAC,aAAa,GAAbA;IACT;IAEH,MAAM,QAAQC,GAAc,EAAE;QAC1B,MAAMC,SAAS,MAAM,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC;YAAED;QAAI;QAEzD,MAAM,IAAI,CAAC,wBAAwB,CAAC,OAAO,CAACA;QAE5C,MAAME,oBAAoB,MAAMD,OAAO,GAAG,CAAC;YACvC,SAAS;gBAAC;gBAAS;aAAS;YAC5B,MAAM,CAAC;YACP,OAAO;gBACH,KAAKE,uBAAuB;oBACxB,gBAAgB;wBAACC;qBAA6B;gBAClD;YACJ;QACJ;QAEA,IAAI;YACA,OAAOC,KAAK,KAAK,CAACH,kBAAkB,MAAM;QAC9C,EAAE,OAAM;YACJ,IAAI,CAAC,aAAa,CAAC,KAAK,CACpB,yCACAA,kBAAkB,MAAM,EACxBF;YAEJ,OAAO;QACX;IACJ;AACJ;AAEO,MAAMM,sBAAsBC,qBAAqB;IACpD,aAAaC;IACb,gBAAgBZ;IAChB,cAAc;QAACa;QAAkBC;QAA0BC;KAAc;AAC7E;AAIO,MAAMC,8BAA8BN;AACpC,MAAMO,qCAAqCjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./PulumiExportService.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./PulumiExportService.js";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PulumiGetConfigPassphraseService } from "../../abstractions/services/PulumiGetConfigPassphraseService.js";
|
|
2
|
+
export declare class DefaultPulumiGetConfigPassphraseService implements PulumiGetConfigPassphraseService.Interface {
|
|
3
|
+
execute(): string;
|
|
4
|
+
}
|
|
5
|
+
export declare const pulumiGetConfigPassphraseService: import("@webiny/di").Implementation<typeof DefaultPulumiGetConfigPassphraseService>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { PulumiGetConfigPassphraseService } from "../../abstractions/services/PulumiGetConfigPassphraseService.js";
|
|
3
|
+
class DefaultPulumiGetConfigPassphraseService {
|
|
4
|
+
execute() {
|
|
5
|
+
return process.env.PULUMI_CONFIG_PASSPHRASE || "webiny";
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
const pulumiGetConfigPassphraseService = createImplementation({
|
|
9
|
+
abstraction: PulumiGetConfigPassphraseService,
|
|
10
|
+
implementation: DefaultPulumiGetConfigPassphraseService,
|
|
11
|
+
dependencies: []
|
|
12
|
+
});
|
|
13
|
+
export { DefaultPulumiGetConfigPassphraseService, pulumiGetConfigPassphraseService };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=PulumiGetConfigPassphraseService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.js","sources":["../../../src/services/PulumiGetConfigPassphraseService/PulumiGetConfigPassphraseService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport { PulumiGetConfigPassphraseService } from \"~/abstractions/services/PulumiGetConfigPassphraseService.js\";\n\nexport class DefaultPulumiGetConfigPassphraseService\n implements PulumiGetConfigPassphraseService.Interface\n{\n execute() {\n return process.env.PULUMI_CONFIG_PASSPHRASE || \"webiny\";\n }\n}\n\nexport const pulumiGetConfigPassphraseService = createImplementation({\n abstraction: PulumiGetConfigPassphraseService,\n implementation: DefaultPulumiGetConfigPassphraseService,\n dependencies: []\n});\n"],"names":["DefaultPulumiGetConfigPassphraseService","process","pulumiGetConfigPassphraseService","createImplementation","PulumiGetConfigPassphraseService"],"mappings":";;AAGO,MAAMA;IAGT,UAAU;QACN,OAAOC,QAAQ,GAAG,CAAC,wBAAwB,IAAI;IACnD;AACJ;AAEO,MAAMC,mCAAmCC,qBAAqB;IACjE,aAAaC;IACb,gBAAgBJ;IAChB,cAAc,EAAE;AACpB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./PulumiGetConfigPassphraseService.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./PulumiGetConfigPassphraseService.js";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PulumiGetSecretsProviderService } from "../../abstractions/services/PulumiGetSecretsProviderService.js";
|
|
2
|
+
export declare class DefaultPulumiGetSecretsProviderService implements PulumiGetSecretsProviderService.Interface {
|
|
3
|
+
execute(): string;
|
|
4
|
+
}
|
|
5
|
+
export declare const pulumiGetSecretsProviderService: import("@webiny/di").Implementation<typeof DefaultPulumiGetSecretsProviderService>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createImplementation } from "@webiny/di";
|
|
2
|
+
import { PulumiGetSecretsProviderService } from "../../abstractions/services/PulumiGetSecretsProviderService.js";
|
|
3
|
+
class DefaultPulumiGetSecretsProviderService {
|
|
4
|
+
execute() {
|
|
5
|
+
return process.env.PULUMI_SECRETS_PROVIDER || "passphrase";
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
const pulumiGetSecretsProviderService = createImplementation({
|
|
9
|
+
abstraction: PulumiGetSecretsProviderService,
|
|
10
|
+
implementation: DefaultPulumiGetSecretsProviderService,
|
|
11
|
+
dependencies: []
|
|
12
|
+
});
|
|
13
|
+
export { DefaultPulumiGetSecretsProviderService, pulumiGetSecretsProviderService };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=PulumiGetSecretsProviderService.js.map
|