{"id":13595183,"url":"https://github.com/pages-cms/pages-cms","last_synced_at":"2025-05-14T07:08:29.113Z","repository":{"id":215916017,"uuid":"732374797","full_name":"pages-cms/pages-cms","owner":"pages-cms","description":"The No-Hassle CMS for Static Sites Generators","archived":false,"fork":false,"pushed_at":"2025-05-09T12:52:38.000Z","size":2355,"stargazers_count":2323,"open_issues_count":43,"forks_count":283,"subscribers_count":20,"default_branch":"main","last_synced_at":"2025-05-09T14:00:39.560Z","etag":null,"topics":["11ty","astro","cms","docusaurus","eleventy","gatsby","hugo","jekyll","nextjs","ssg","static-site","static-site-generator","vitepress","vue","vuejs","vuejs3","vuepress"],"latest_commit_sha":null,"homepage":"https://pagescms.org","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pages-cms.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["hunvreus"]}},"created_at":"2023-12-16T13:20:51.000Z","updated_at":"2025-05-09T12:52:42.000Z","dependencies_parsed_at":"2024-03-02T05:27:51.694Z","dependency_job_id":"3e0152c1-979c-4663-abb0-4924d4cb68fc","html_url":"https://github.com/pages-cms/pages-cms","commit_stats":{"total_commits":78,"total_committers":1,"mean_commits":78.0,"dds":0.0,"last_synced_commit":"00f2eb51577b6f9403cd74cfb3c547c680a27602"},"previous_names":["pages-cms/pages-cms"],"tags_count":36,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pages-cms%2Fpages-cms","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pages-cms%2Fpages-cms/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pages-cms%2Fpages-cms/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pages-cms%2Fpages-cms/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pages-cms","download_url":"https://codeload.github.com/pages-cms/pages-cms/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254092776,"owners_count":22013290,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["11ty","astro","cms","docusaurus","eleventy","gatsby","hugo","jekyll","nextjs","ssg","static-site","static-site-generator","vitepress","vue","vuejs","vuejs3","vuepress"],"created_at":"2024-08-01T16:01:45.451Z","updated_at":"2025-05-14T07:08:29.097Z","avatar_url":"https://github.com/pages-cms.png","language":"TypeScript","readme":"# Pages CMS\n\n[Pages CMS](https://pagescms.org) is an Open Source Content Management System for GitHub. It is particularly well suited for static site generators (e.g. Jekyll, Next.js, VuePress, Hugo).\n\nIt offers a user-friendly interface to edit the content of your website or app directly on GitHub.\n\n\u003ca href=\"https://demo.pagescms.org\" target=\"_blank\"\u003e\n\u003cpicture\u003e\n\u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://pagescms.org/media/screenshots/nextjs-edit-with-bg-dark@2x.png\"\u003e\n\u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://pagescms.org/media/screenshots/nextjs-edit-with-bg-light@2x.png\"\u003e\n\u003cimg src=\"https://pagescms.org/media/screenshots/nextjs-edit-with-bg-light@2x.png\"\u003e\n\u003c/picture\u003e\n\u003c/a\u003e\n\n*[Watch the demo ▶](https://demo.pagescms.org)*\n\n## Documentation\n\nGo to [pagescms.org/docs](https://pagescms.org/docs).\n\n## Community chat\n\n[Join the Discord server](https://pagescms.org/chat) to get help with Pages CMS, share feedback, and connect with other users building with the platform.\n\n## Built with\n\n- [Next.js](https://nextjs.org/)\n- [Tailwind CSS](https://tailwindcss.com/)\n- [shadcn/ui](https://ui.shadcn.com/)\n- [drizzle](https://orm.drizzle.team/)\n- [Vercel](https://vercel.com/)\n- [Turso](https://turso.tech/)\n- [Resend](https://resend.com/)\n\n## Use online\n\nThe easiest way to get started is to use [the online version of Pages CMS](https://app.pagescms.org). You'll be able to log in with your GitHub account and get the latest version of Pages CMS.\n\nThis online version is identical to what's in this repo, but you can also install your own version locally or deploy it (for free) on Vercel following the steps below.\n\n## Install and Deploy\n\n### Create a GitHub App\n\nWhether you're installing Pages CMS locally or deploying it online, you will need a GitHub App.\n\nYou can either create it under your personal account (https://github.com/settings/apps) or under one of your organizations (https://github.com/organizations/\u003corg-name\u003e/settings/apps).\n\nYou will need to fill in the following information:\n\n- **GitHub App name**: use \"Pages CMS\" or whatever you think is appropriate (e.g. \"Pages CMS (dev)\").\n- **Homepage URL**: whatever you want, https://pagescms.org will do.\n- **Identifying and authorizing users**:\n    - Callback URL: the URL for `/api/auth/github`:\n        - `http://localhost:3000/api/auth/github` for development,\n        - something like `https://my-vercel-url.vercel.app/api/auth/github` (or whatever custom domain you're using) if you're deploying on Vercel.\n    - Expire user authorization tokens: no.\n    - Request user authorization (OAuth) during installation: yes.\n    - Enable Device Flow: no.\n- **Post installation**:\n    - Setup URL (optional): leave empty.\n    - Redirect on update: no.\n- **Webhook**:\n    - Active: yes.\n    - Webhook URL: the (public) URL for `/api/webhook/github`:\n        - for development, you'll need to use something like [ngrok](https://ngrok.com/). You'll end up with something like `https://your-unique-subdomain.ngrok-free.app/api/webhook/github`.\n        - something like `https://my-vercel-url.vercel.app/api/webhook/github` (or whatever custom domain you're using) if you're deploying on Vercel.\n    - Secret: generate a random string (for example with `openssl rand -base64 32` on MacOS/Linux)\n- **Permissions**:\n    - Repository permissions:\n        - Administration: Read \u0026 Write\n        - Contents: Read \u0026 Write\n        - Metadata: Read only\n    - Organization permissions: nothing.\n    - Account permissions: nothing.\n- **Subscribe to events**:\n    - Installation target\n    - Repository\n    - Push\n    - Delete\n- **Where can this GitHub App be installed?**: you'll want to select \"Any account\" unless you intend to only use Pages CMS on the account this GitHub App is created under.\n\n### Environment variables\n\nVariable | Comments\n--- | ---\n`CRYPTO_KEY` | Used to encrypt/decrypt GitHub tokens in the database. On MacOS/Linux*, you can use `openssl rand -base64 32`.\n`GITHUB_APP_ID` | GitHub App ID from your GitHub App details page.\n`GITHUB_APP_NAME` | Machine name for your GitHub App (e.g. `pages-cms`), should be the slug the URL of your GitHub App details page.\n`GITHUB_APP_PRIVATE_KEY` | PEM file you can download upong creation of the GitHub App.\n`GITHUB_APP_WEBHOOK_SECRET` | The secret you picked for your webhook. This is used to ensure the request is coming from GitHub.\n`GITHUB_APP_CLIENT_ID` | GitHub App Client ID from your GitHub App details page.\n`GITHUB_APP_CLIENT_SECRET` | GitHub App Client Secret you generate on theGitHub App details page.\n`RESEND_FROM_EMAIL` | The sender for authentication emails. Must be a verified domain in your Resend account and follow the format `email@example.com` or `Name \u003cemail@example.com\u003e`.\n`RESEND_API_KEY` | You'll get that when you create a (free) [Resend](https://resend.com) account to handle emails.\n`SQLITE_URL` | `file:./local.db` for development, `libsql://pages-cms-username.turso.io` for example if you use [Turso](https://turso.tech) (you should, Turso is great).\n`SQLITE_AUTH_TOKEN` | Leave blank for development, otherwise use the token provided by [Turso](https://turso.tech) (if that's what you use).\n`BASE_URL` | **OPTIONAL**. If you're deploying to Vercel or working locally, you won't need that. If you're deploying elsewhere, you'll need to specify the base URL for the app (e.g. `https://mycustomdomain.com`).\n`FILE_CACHE_TTL` | **OPTIONAL**. Time to live (in minutes) for file cache (collections and\nmedia folders). Defaults to 10080 (7 days). Set to \"-1\" to prevent the cache from ever expiring, or \"0\" if you want no cache.\n`PERMISSION_CACHE_TTL` | **OPTIONAL**. Time to live (in minutes) for the permission cache, which controls access to file cache. Defaults to 60. Set to \"0\" if you want to always check permissions against the GitHub API.\n\n### Local development\n\nWe assume you've already created the GitHub App and have a running tunnel for the GitHub App Webhook (using [ngrok](https://ngrok.com/) for example):\n\n1. **Install the dependencies**: `npm install`\n2. **Update your environment variables**: copy `.env.example` to `.env` and fill in the values according to your setting (see section above).\n3. **Create the database**: `npm run db:migrate`\n4. **Run it**: `npm run dev`\n\n### Deploy on Vercel\n\n1. **Create a SQLite database**: I recommend using [Turso](https://turso.tech), because it's free (and pretty awesome)\n2. **Deploy to Vercel**: at this stage you have 2 choices:\n    1. **Create a fork**: fork the `pages-cms/pages-cms` repo in your account and deploy that fork. This will allow you to get updates. **Make sure you define all of the environment variables listed above**.\n    2. **Use the deploy button**:\n    \n        [![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fpages-cms%2Fpages-cms%2Ftree%2Fmain\u0026project-name=pages-cms\u0026repository-name=pages-cms\u0026redirect-url=https%3A%2F%2Fpagescms.org\u0026env=CRYPTO_KEY,GITHUB_APP_ID,GITHUB_APP_NAME,GITHUB_APP_PRIVATE_KEY,GITHUB_APP_WEBHOOK_SECRET,GITHUB_APP_CLIENT_ID,GITHUB_APP_CLIENT_SECRET,RESEND_API_KEY,SQLITE_URL,SQLITE_AUTH_TOKEN)\n\n3. **Update your GitHub OAuth app**: you'll probably need to go back to your GitHub App settings to update some of the settings once you have the Vercel URL (e.g. \"Callback URL\" and \"Webhook URL\").\n\n### Self-host\n\nThere are [plenty of other options](https://nextjs.org/docs/app/building-your-application/deploying#self-hosting): Fly.io, Digital Ocean, Render, SST, etc.\n\n## License\n\nEverything in this repo is released under the [MIT License](LICENSE).","funding_links":["https://github.com/sponsors/hunvreus"],"categories":["TypeScript","Vue","astro","前端开发框架及项目"],"sub_categories":["多工具库支持或纯JS"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpages-cms%2Fpages-cms","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpages-cms%2Fpages-cms","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpages-cms%2Fpages-cms/lists"}