npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@scaffoldly/terraform-aws-serverless-api-stage

v1.0.49

Published

Configure API Gateway for a Serverless API on a given stage:

Downloads

6

Readme

Maintained by Scaffoldly GitHub release (latest SemVer) Terraform Version

Description

Configure API Gateway for a Serverless API on a given stage:

  • Rest API
  • Cloudwatch Log Group
  • Generalized CORS Response Templates
  • Health Endpoint
  • First deployment for the Health Endpoint
  • A Stage with Logging Configuration
  • The Base Path Mapping
  • IAM Roles

Usage

module "stage" {
  source = "scaffoldly/serverless-api-stage/aws"

  for_each = var.stage_domains

  domain         = lookup(each.value, "serverless_api_domain", "unknown-domain")
  stage_env_vars = lookup(each.value, "stage_env_vars", {})

  name  = var.name
  stage = each.key

  repository_name = module.repository.name

  depends_on = [
    module.repository
  ]
}

Requirements

| Name | Version | |------|---------| | terraform | >= 1.2, < 1.7 |

Providers

| Name | Version | |------|---------| | aws | 3.55.0 |

Modules

| Name | Source | Version | |------|--------|---------| | bucket | scaffoldly/s3-private-versioned/aws | 1.0.9 | | health | scaffoldly/api-gateway-static-endpoint/aws | 1.0.3 | | iam | scaffoldly/serverless-api-stage-iam/aws | 1.0.16 | | websocket | scaffoldly/serverless-api-stage-websocket/aws | 1.0.9 |

Resources

| Name | Type | |------|------| | aws_api_gateway_base_path_mapping.mapping | resource | | aws_api_gateway_deployment.deployment | resource | | aws_api_gateway_gateway_response.cors_responses | resource | | aws_api_gateway_method_settings.settings | resource | | aws_api_gateway_rest_api.api | resource | | aws_api_gateway_stage.stage | resource | | aws_cloudwatch_log_group.execution_group | resource | | aws_cloudwatch_log_group.group | resource | | aws_sns_topic.topic | resource | | aws_sns_topic_policy.policy | resource | | aws_caller_identity.current | data source | | aws_partition.current | data source |

Inputs

| Name | Description | Type | Default | Required | |------|-------------|------|---------|:--------:| | bucket_allow_public_access | Allow Objects in the bucket with a Public ACL | bool | false | no | | bucket_name | Set the bucket name, default: var.repository_name | string | "" | no | | create_bucket | Create an S3 Bucket for the Service | bool | true | no | | create_topic | Create SNS Topics for the service | bool | true | no | | domain | The domain for the Serverless API | string | "" | no | | path | The name of the Serverless API | string | "" | no | | regional | If true, create a regional Serverless API | bool | false | no | | repository_name | The GitHub Repository Name | string | n/a | yes | | root_principal | The root prinicipal. In most cases leave this as 'root' | string | "root" | no | | saml_trust | Output of trust from saml-to/iam/aws module | object({ trust_actions = list(string) trust_principal_identifiers = list(string) trust_principal_type = string trust_condition_saml_test = string trust_condition_saml_variable = string trust_condition_saml_values = list(string) } ) | null | no | | stage | The stage (e.g. live, nonlive) | string | n/a | yes | | stage_kms_key_id | The KMS Key ID for the stage (optional) | string | "" | no | | websocket | (Optional) Enable a websocket for this stage | bool | false | no | | websocket_domain | (Optional) The custom domain for the websocket (if using a custom domain) | string | "" | no |

Outputs

| Name | Description | |------|-------------| | api_id | The Rest API ID | | base_path | Computed path for the service, below the domain (/{servicename}) | | bucket_name | n/a | | domain | Computed domain name (https://{domain}) | | name | Re-output of the stage name | | repository_name | Re-output of the repository name | | rest_url | Full HTTP url to the service | | role_arn | n/a | | root_resource_id | The Rest API Root Resource ID | | s3_topic_arn | n/a | | stage | Re-output of the var.stage | | topic_arn | n/a | | url | Full HTTP url to the service (https://{domain}/{servicename}) | | websocket_api_id | The websocket API ID, if enabled, otherwise null | | websocket_url | The websocket URL, if enabled, otherwise null |