All Projects → phantomstudios → strapi-plugin-github-publish

phantomstudios / strapi-plugin-github-publish

Licence: MIT license
This is a plugin for Strapi headless CMS. It lets you trigger a GitHub Action workflow when the site is ready to be published.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to strapi-plugin-github-publish

strapi-plugin-import-export-content
Csv and Json import / export content plugin to Strapi
Stars: ✭ 129 (+268.57%)
Mutual labels:  strapi, strapi-plugin
strapi-plugin-sync-roles-permissions
Store user roles and permissions configuration as a JSON file and then import and reuse it any time.
Stars: ✭ 34 (-2.86%)
Mutual labels:  strapi, strapi-plugin
strapi-plugin-zeasy-image-api
Strapi plugin to ease the process importing Unsplash image with attribution
Stars: ✭ 28 (-20%)
Mutual labels:  strapi, strapi-plugin
strapi-plugin-migrate
Strapi-Plugin-Migrate helps to migrate Strapi data from one environment of your app to another. For example development > staging
Stars: ✭ 71 (+102.86%)
Mutual labels:  strapi, strapi-plugin
strapi-plugin-vercel
▲ Strapi plugin for Vercel Platform
Stars: ✭ 28 (-20%)
Mutual labels:  strapi, strapi-plugin
strapi-plugin-sitemap
🔌 Generate a highly customizable sitemap XML in Strapi CMS
Stars: ✭ 136 (+288.57%)
Mutual labels:  strapi, strapi-plugin
Starter
A development starter theme for Ghost
Stars: ✭ 195 (+457.14%)
Mutual labels:  publishing
rentry
Markdown pastebin from command line
Stars: ✭ 252 (+620%)
Mutual labels:  publishing
Casper
The default theme for Ghost
Stars: ✭ 2,274 (+6397.14%)
Mutual labels:  publishing
Writefreely
A clean, Markdown-based publishing platform made for writers. Write together, and build a community.
Stars: ✭ 2,479 (+6982.86%)
Mutual labels:  publishing
elife-xpub
eLife is an open-access journal and technology provider that publishes promising research in the life and biomedical sciences. This is their implementation of a submission and peer review system based on Coko PubSweet and xPub.
Stars: ✭ 29 (-17.14%)
Mutual labels:  publishing
strapi-tinymce
Strapi extension to overwrite the current Wysiwyg by Tinymce
Stars: ✭ 39 (+11.43%)
Mutual labels:  strapi
Open Publisher
Using Jekyll to create outputs that can be used as Pandoc inputs. In short - input markdown, output mobi, epub, pdf, and print-ready pdf. With a focus on fiction.
Stars: ✭ 242 (+591.43%)
Mutual labels:  publishing
London
A free, open source theme for Ghost
Stars: ✭ 212 (+505.71%)
Mutual labels:  publishing
pwpub
W3C packaged Web Publications
Stars: ✭ 14 (-60%)
Mutual labels:  publishing
Lines Engine
Lines is a customizable blog framework for Rails. It aims at making publishing simple and beautiful.
Stars: ✭ 191 (+445.71%)
Mutual labels:  publishing
Asgar
A two-column, clean and minimalist theme for @TryGhost
Stars: ✭ 22 (-37.14%)
Mutual labels:  publishing
Manshar
NO LONGER BEING MAINTAINED - Arabic social publishing platform — منصة نشر مخصصة للغة العربية
Stars: ✭ 180 (+414.29%)
Mutual labels:  publishing
Google Docs Publisher
Publish good looking Google Docs
Stars: ✭ 230 (+557.14%)
Mutual labels:  publishing
ox-leanpub
Org-mode exporter for Leanpub books - mirrored from GitLab
Stars: ✭ 18 (-48.57%)
Mutual labels:  publishing

Strapi plugin github-publish

NPM version Actions Status PR Welcome

This is a plugin for Strapi headless CMS. It lets you trigger a GitHub Action workflow when the site is ready to be published.

Introduction

Screenshot

When using Strapi as a headless CMS for a statically built website you need a way to trigger the site to rebuild when content has been updated. The typical approach is to setup a Strapi managed webhook to trigger a CI/CD pipeline whenever content changes. This approach has it's issues. For example when making many changes to content, builds are triggered multiple times and deployments can fail due to the site being deployed concurrently.

This plugin tackles the publishing flow a different way. The site administrators can take their time and make many changes and once the content update is complete they can trigger a single build.

This plugin also checks to see if an in_progress build is active or if anything is in the queue and not allow the user to trigger another. Also, when a build has been triggered the user can wait on the plugin page to see when the build and deployment has completed.

Installation

Install this plugin with npm or yarn.

With npm:

npm install strapi-plugin-github-publish

With yarn:

yarn add strapi-plugin-github-publish

Configuration

Generate a config file at config/plugins.js or config/development/plugins.js etc...

module.exports = ({ env }) => ({
  "github-publish": {
    enabled: true,
    config: {
      owner: "username", // The GitHub organisation or user
      repo: "reponame", // The name of the repository
      workflow_id: "rebuild.yml", // The workflow_id or filename
      token: env("GITHUB_TOKEN"), // The GitHub personal access token with access to trigger workflows and view build status
      branch: "master", // The branch the workflow should be triggered on
      inputs: {
        // Optional inputs to pass through to the GitHub workflow
        some_input: "Some value",
        some_other_input: "Some other value",
      },
    },
  },
});

Make sure you have variable in your .env file

GITHUB_TOKEN=XXXXXXX

Use the Plugin

When the plugin has been installed correctly just click on GitHub Publishing in the sidebar under plugins then click "Publish".

Older Strapi versions

To use this plugin on a Strapi version prior to v4, install using:

npm install [email protected]

Then generate a config file at config/plugins.js or config/development/plugins.js etc... with:

module.exports = ({ env }) => ({
  "github-publish": {
    owner: "username", // The GitHub organisation or user
    repo: "reponame", // The name of the repository
    workflow_id: "rebuild.yml", // The workflow_id or filename
    token: env("GITHUB_TOKEN"), // The GitHub personal access token with access to trigger workflows and view build status
    branch: "master", // The branch the workflow should be triggered on
    inputs: {
      // Optional inputs to pass through to the GitHub workflow
      some_input: "Some value",
      some_other_input: "Some other value",
    },
  },
});
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].