Skip to content

ritsok/clay-starter

 
 

Repository files navigation

Clay Starter

A basic starter for Clay

Docs

Documentation around Clay is being refined in cojunction with iteration on this starter. For beginning documentation about Clay and its data structures you can browse this link: https://claycms.gitbook.io/clay/

Requirements

Assumptions

  • This repo uses Google for OAuth by default. To use your Google account to authenticate locally change the username field in sample_users.yml
  • You're running Node 8.12.0 or greater
  • You've installed Clay CLI

Setup

Clone the repo and run the following commands:

You should be able to navigate to http://localhost/_pages/sample-article.html to see an article page render!

Accessing The Edit UI

The edit interface of Clay is a component itself called Kiln! To begin editing with the UI you'll need to make sure you've run make boostrap-user after replacing the sample user with your own Gmail address.

Once you're done that you can access edit mode from any page by adding ?edit=true or by holding down Shift and typing CLAY. For example, navigating to http://localhost/_pages/sample-article.html?edit=true will grant you access to the edit interface.

Stopping & Clearing Out Data

  • make burn (Stops and removes all service containers)
  • make clear-data (Removes all local data)
  • make clear-public (Removes the app/public directory which is Express' static asset directory)

What's Running?

The project consists of four services running in Docker and Clay running on your host machine.

  • NGINX: locally it allows us to forward port 80 to Clay to make working with Clay easy. The current configuration is set to only route requests to localhost. If you want to change the host that clay listens to you'll need to update the NGINX config
  • Postgres: the primary data store for Clay data
  • Redis: locally this container is the cache for Postgres, the session store for PassportJS and the event bus for Clay
  • ElasticSearch: integrated for search functionality

About

A basic starter kit for Clay

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 58.4%
  • CSS 23.6%
  • HTML 14.3%
  • Shell 1.5%
  • Makefile 1.2%
  • Dockerfile 0.9%
  • HCL 0.1%