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

Support Vercel #180

Merged
merged 8 commits into from
Nov 3, 2020
Merged

Support Vercel #180

merged 8 commits into from
Nov 3, 2020

Conversation

elliottsj
Copy link
Contributor

Closes #174


### 1. Deploy to Vercel

[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/git/external?repository-url=https%3A%2F%2Fgithub.com%2Felecterious%2FAckee&env=ACKEE_USERNAME,ACKEE_PASSWORD,ACKEE_MONGODB,ACKEE_ALLOW_ORIGIN&envDescription=Environment%20variables%20needed%20to%20configure%20the%20user%20and%20database%20connection&envLink=https%3A%2F%2Fgithub.com%2Felecterious%2FAckee%2Fblob%2Fmaster%2Fdocs%2FOptions.md)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This button was constructed via https://vercel.com/docs/more/deploy-button.

It tells Vercel to prompt the user for required environment variables ACKEE_USERNAME, ACKEE_PASSWORD, ACKEE_MONGODB, and ACKEE_ALLOW_ORIGIN.

@@ -115,6 +115,6 @@
}
},
"engines": {
"node": ">= 14"
"node": ">= 12"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

In my brief testing, I didn't notice any crashes or issues on Node.js 12.

{
"build": {
"env": {
"NODEJS_AWS_HANDLER_NAME": "handler"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is needed so Vercel treats the serverless function as an AWS Lambda function. See https://vercel.com/docs/runtimes#advanced-usage/advanced-node-js-usage/aws-lambda-api and the docstring in api/index.js.

Comment on lines +36 to +37
.vercel
Copy link
Contributor Author

Choose a reason for hiding this comment

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

When using the Vercel CLI in this project, a .vercel directory is created with some generated files that shouldn't be committed.

@coveralls
Copy link

coveralls commented Nov 1, 2020

Pull Request Test Coverage Report for Build 689

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 44.534%

Totals Coverage Status
Change from base Build 685: 0.0%
Covered Lines: 457
Relevant Lines: 823

💛 - Coveralls

@electerious electerious changed the base branch from master to develop November 2, 2020 07:28
@electerious
Copy link
Owner

So good 💯 Big props for the great PR and for adding code comments on GitHub. Will merge it as soon as I have time to test it!

@electerious electerious merged commit 6cf0c2c into electerious:develop Nov 3, 2020
@elliottsj elliottsj deleted the vercel branch November 3, 2020 16:09
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.

Deployment to Vercel
4 participants