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

Easier setup #865

Open
PatrickCleary opened this issue Sep 22, 2023 · 5 comments
Open

Easier setup #865

PatrickCleary opened this issue Sep 22, 2023 · 5 comments
Labels
backend Change to backend code feature New feature or request help wanted Extra attention is needed optimization Optimizing some exisiting functionality

Comments

@PatrickCleary
Copy link
Member

It would be nice to allow for potential contributors to get the dashboard up & running w/o AWS/DD/MBTA creds.

Could set it up so the dashboard hits prod endpoints unless a flag is present (or vice versa).

@PatrickCleary PatrickCleary added feature New feature or request help wanted Extra attention is needed optimization Optimizing some exisiting functionality backend Change to backend code labels Sep 22, 2023
@PatrickCleary
Copy link
Member Author

PatrickCleary commented Sep 23, 2023

I started working on this.

I tried to set it up so localhost would hit the beta API. This causes CORS issues. So I started working on the Chalice CORS config on the beta APIs to accept the Beta URL as well as localhost URLS.

Chalice doesn't have built in support for multiple origins. See: https://aws.github.io/chalice/tutorials/basicrestapi.html#cors-support

Worked on setting that up but facing issues.

I alos just realized it says "May not work on all clients" so maybe since this is for developers only we can just use an array of origins? idk.

@PatrickCleary
Copy link
Member Author

@sutt
Copy link

sutt commented Sep 26, 2023

Is there a way to sync with an existing database of historical data? Or do you just start scraping current trips when you launch the app?

@rudiejd
Copy link
Contributor

rudiejd commented Dec 9, 2023

in order to get this set up without actually deploying a lambda, I had to create my own copy of the DeliveredTripMetrics dynamo table in personal AWS and run the populate_delivered_trip_metrics function from the data ingestion repository: https://github.com/transitmatters/data-ingestion/blob/main/ingestor/app.py#L129

then repeat for the other tables. it seems like maybe the repo could ship with a dynamodb localstack setup with some of these tables preloaded

@PatrickCleary
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Change to backend code feature New feature or request help wanted Extra attention is needed optimization Optimizing some exisiting functionality
Projects
None yet
Development

No branches or pull requests

3 participants