1
0
Fork 0
mirror of https://github.com/kou029w/http-echo.git synced 2025-01-18 08:05:06 +00:00

create netlify project files

This commit is contained in:
Nebel 2020-05-16 20:55:07 +09:00
parent 9921947e1c
commit b5f546a118
4 changed files with 16 additions and 0 deletions

2
.gitignore vendored
View file

@ -1,4 +1,6 @@
/node_modules/
/package-lock.json
/.env
/.netlify/*
!/.netlify/functions
/.vercel

View file

@ -0,0 +1,7 @@
const awsServerlessExpress = require("aws-serverless-express");
const app = require("../../../index.js");
const server = awsServerlessExpress.createServer(app);
exports.handler = (event, context) => {
awsServerlessExpress.proxy(server, event, context);
};

6
netlify.toml Normal file
View file

@ -0,0 +1,6 @@
[build]
functions = ".netlify/functions"
[[redirects]]
from = "/*"
to = "/.netlify/functions/app"
status = 200

View file

@ -8,6 +8,7 @@
"start": "node -r dotenv/config index.js"
},
"dependencies": {
"aws-serverless-express": "latest",
"cookie-parser": "latest",
"express": "latest",
"morgan": "latest",