Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[coepi-backend-aws]: Create a domain api.coepi.org and redirect the Cloud API endpoint to that URL #8

Open
ramnanib2 opened this issue Apr 10, 2020 · 7 comments

Comments

@ramnanib2
Copy link
Collaborator

No description provided.

@bleggett
Copy link

Is there any reason why we shouldn't do this via Route53?

@ramnanib2
Copy link
Collaborator Author

I don't see why not. Just confirm with Scott

@scottleibrand
Copy link

Not sure where we left this after the Slack conversation. It's easier for me to do the CNAME / A record directly with my registrar than to delegate a zone to R53 if we're just doing the single hostname. But if there are significant advantages to delegating api.coepi.org to R53, also happy to do that. If not, just LMK what hostname. you want it CNAMEd to.

@ramnanib2
Copy link
Collaborator Author

The current working endpoint that can be CNAMEd to is this one -> https://18ye1iivg6.execute-api.us-west-1.amazonaws.com

The full API endpoint for v4 looks like this:
https://18ye1iivg6.execute-api.us-west-1.amazonaws.com/tcnreport/v4

which should translate to
https://api.coepi.org/tcnreport/v4

We can then use the below strategy to keep the same hostname and proceed with versioning:
https://dzone.com/articles/api-versioning-approach-with-aws-api-gateway

@bleggett
Copy link

bleggett commented Apr 22, 2020

@scottleibrand @bhushanRamnani The issue is that endpoints exposed by API Gateway are not "fixed" if the API gateway is recreated - this means that we'd have to get @scottleibrand to update the CNAME manually every time the API Gateway is (re)created if we just point the existing CNAME to the AWS API Gateway. This seems like something worth avoiding.

Best option is to set up a "custom" fixed API DNS in R53 that doesn't change and have @scottleibrand point his CNAME at that, I think?

@bleggett bleggett self-assigned this Apr 22, 2020
@scottleibrand
Copy link

scottleibrand commented Apr 23, 2020

Ok, I've CNAMEd api.coepi.org to 18ye1iivg6.execute-api.us-west-1.amazonaws.com for now, and can update that to point to a R53 target once y'all create it.

@ramnanib2
Copy link
Collaborator Author

Getting a certificate error ->

f0189818d391:~ ramnanib$ curl -X GET https://api.coepi.org/v4/tcnreport
curl: (35) error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol

@bleggett bleggett removed their assignment Apr 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants