Deployment

Generating static content

cmints --static

By running command above your static website should be ready and located in the content directory, you can copy the content of the directory to any static hosting of your choice, but you can also use the advantage of the existing tools and deployment integrations in the CMintS to make that much more simpler.

Github pages

GitHub Pages is a static site hosting service designed to host project pages directly from a GitHub repository. You can host CMintS projects for free in the GitHub Pages, by simply running the command below, considering that you are using GitHub as your git hosting:

cmints --static --deploy

Other git based hostings

The command in the Github pages section, deploys to the gh-pages branch. If you would like to push to another branch of the git repository(not neceseraly Github repository) you can do so by specifying the deployment branch in the configuration file, as shown in the example below:

const deployment =
{
  where: "git",
  branch: "deployment-branch"
};

module.exports = {deployment};

Netlify

Netlify provides Git-triggered continuous integration deployment hosting, that means it can build and make your website accessible each time your push changes to the repository.

There are several ways you can use Netlify:

Continuous Deployment

Navigate to the start page, connect to your Git hosting provider and choose a CMintS project repository.

Use options below in the building options page:

  • Branch to deploy - specify the project build branch usually it's the master branch.
  • Build command - cmints --static (Static site generation).
  • Publish directory - content (Default project output directory of CMintS)

CLI

Netlify’s command line interface lets you deploy sites or configure continuous deployment straight from the command line.

Deploy to Netlify Button

The “Deploy to Netlify” button helps users deploy sites from templates with one single click. It provides web developers a simple one-click step to let their users deploy those applications on Netlify.