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

[233] Add lambda handler and deployment steps #306

Merged
merged 5 commits into from
Sep 20, 2020

Conversation

arturtamborski
Copy link
Member

Story / Bug id:

#233

Description:

I finally implemented it!

Migrations:

N/A

New imports / dependencies:

new:
serverless_wsgi==1.7.5
upgrade:
psycopg2-binary==2.8.5
Flask-SQLAlchemy==2.4.4

What tests do I need to run to validate this change:

go to dev.codeforpoznan.pl and try it out! :D
credentials: admin:pass123

@OtisRed
Copy link
Contributor

OtisRed commented Sep 11, 2020

@arturtamborski I must have done sth wrong :D It seems like the request is rejected because api has http instead of https address and hence take it as insecure connection.

Zrzut ekranu z 2020-09-11 21-14-28

@arturtamborski
Copy link
Member Author

Yea, to be fair I'm still working on the details here. Lambda itself works fine, migrations are running OK, the schema was created and you can run the app with remote DB just fine, so it's nearly finished, but I still have to tweak the frontend code a bit.

For some odd reason axios is pumping all requests to 0.0.0.0:5000 instead of the proper host, so that's on my mind right now.
Other than that I sure think it's finally ready! :D

@OtisRed OtisRed mentioned this pull request Sep 11, 2020
@arturtamborski arturtamborski marked this pull request as ready for review September 11, 2020 21:18
@arturtamborski
Copy link
Member Author

arturtamborski commented Sep 11, 2020

Update: axios is now working fine which makes this PR ready for a review.

List of things to do / check in future:

  1. e-mails. I have no idea if that piece of code in emails will be enough in terms of the app logic. We still have to set up SES for mail forwarding but that's a story for another time.
  2. migrations. We have one handy PR that will let us test the migrations swiftly and I'm sure they will work fine but as always in these cases, this assumption is still to be confirmed.
  3. caching. Something is wrong with the way API gateway returns responses and I'm blaming caching for that. I'll check that as my first priority because it severely affects the way app works.
    UPDATE, this is now fixed in Change handler in cfp-v3 lambda infrastructure#74

But taking things aside - its working just fine. The login works, frontend works, backend works, migrations are working and its a good (although very late) start! :)

Copy link
Contributor

@jacekkalbarczyk jacekkalbarczyk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works fine, nothing to add here.

@arturtamborski arturtamborski merged commit 13d8a5d into CodeForPoznan:master Sep 20, 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

Successfully merging this pull request may close these issues.

3 participants