-
-
Notifications
You must be signed in to change notification settings - Fork 362
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
Support Vercel #180
Conversation
|
||
### 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) |
There was a problem hiding this comment.
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" |
There was a problem hiding this comment.
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" |
There was a problem hiding this comment.
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
.
.vercel |
There was a problem hiding this comment.
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.
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! |
Closes #174