0.1.0 • Published 3 years ago

serverless-headless-cms v0.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

Serverless Headless CMS using Firebase

demo

Demo: Vercel / Firebase Hosting

Development

Create .env file.

NEXT_PUBLIC_FIREBASE_CONFIG={"apiKey":"AIzaSy..."}
yarn
yarn dev

Open http://localhost:3000 with your browser to see the result.

Deployment

git clone https://github.com/yamitzky/serverless-headless-cms.git
cd serverless-headless-cms

# create and edit .env, or set environment variable
NEXT_PUBLIC_FIREBASE_CONFIG={"apiKey":"AIzaSy..."}
# Optional: configure CMS
NEXT_PUBLIC_CMS_CONFIG={"resourcesPath":"{{rid}}","resourcePath":"{{rid}}/{{iid}}","userAppsPath":"users/_/applications","userAppPath":"users/_/applications/{{id}}","title":"Your CMS","hideGitHubLogo":true,"hideLandingPage":true,"authMethods":["google"],"singleProject":true,"schemaPermission":"owner","securityPermission":"owner"}

# deploy to firebase
yarn install
yarn deploy --project {project_id}
# yarn deploy --project {project_id} --site {site_id}