up icon indicating copy to clipboard operation
up copied to clipboard

Deploy Edge-Optimised, Regional or Private gateway API

Open aronneagu opened this issue 6 years ago • 6 comments

Prerequisites

  • [x] I am running the latest version. (up upgrade)
  • [x] I searched to see if the issue already exists.
  • [x] I inspected the verbose debug output with the -v, --verbose flag.
  • [x] Are you an Up Pro subscriber?

Description

I would like to request the possibility of specifying the endpoint type for the API Gateway; the currently supported values are Regional, Edge-optimised and Private. As far as I can see apex-up creates Edge-Optimised endpoint by default

The documentation for Regional and Private API are here: https://docs.aws.amazon.com/apigateway/latest/developerguide/create-regional-api.html https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-private-apis.html

I have the use case where I want to create an API Gateway that takes requests from multiple EC2 instances, which are located in the same region, so it makes sense to a Regional API.

Steps to Reproduce

Love Up?

Absolutely loving it! By far the best polished product I have ever seen

aronneagu avatar Jun 19 '18 09:06 aronneagu

First of all thanks :D

As far as regional goes they were missing a CloudFormation setting which made it not possible a month or two ago, but I'll check that out again maybe it's ok now

tj avatar Jun 19 '18 15:06 tj

Sounds like the regional portion still has an issue, I just saw someone in the CloudFormation Slack saying they hit the same limitation, but it should be a quick thing for AWS to add

tj avatar Jun 19 '18 16:06 tj

Hey TJ, Thanks for getting back so fast. That's a shame that Cloudformation is missing that bit of functionality. For the moment I can manually change the Endpoint type from Edge-optimized to Regional via the AWS Console, so it's not really a blocker.

aronneagu avatar Jun 19 '18 16:06 aronneagu

I'd be interested in the private endpoints if this is at all possible.

spidie avatar Aug 26 '18 19:08 spidie

@tj Support seems to be there now https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-restapi.html https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apigateway-restapi-endpointconfiguration.html

Could we get this added? I'm stuck on using Up just because I need a regional endpoint without a CloudFront distribution.

sudhirj avatar Nov 01 '18 07:11 sudhirj

It's a little wonky since we need to provision the ACM cert in the region as well, but I'll try to get that in and QA'd soon (moving this week :D)!

  • [x] add endpoint config
  • [x] add regional cert provisioning
  • [x] add config validation
  • [ ] document (seems to require re-creation, errors with "Request would rotate edge endpoint certificate, create regional endpoint" otherwise, need to look into that)
  • [ ] QA existing apps / edge
  • [ ] QA regional

tj avatar Nov 01 '18 17:11 tj