A headless git based CMS for managing content for guidance pages.
- Add a new page
- Edit a page
- Delete a page
- View a page
- View a page history
- Rollback to a previous version of a page
- Add a new version of a page
- Edit a version of a page
- Delete a version of a page
- Clone the repository
- Run
source .venv/bin/activate
- Run
python -m venv .venv
- Run
pip install -r requirements.txt
- Run
fastapi dev main.py
- Clone the repository
- Make sure you have Docker and Docker Compose installed
- Build and start the containers:
docker compose up --build
- For subsequent runs, simply use:
docker compose up
- To stop the containers:
docker compose down
The application will be available at http://localhost:8000
in both cases.
- The application uses hot-reload, so any changes you make to the code will automatically trigger a reload
- Application logs can be viewed using
docker compose logs -f
- To run commands inside the container:
docker compose exec web <command>
The API is available at http://localhost:8000
curl -X GET "http://localhost:8000/collections"
curl -X GET "http://localhost:8000/collections/{collection_id}"
curl -X GET "http://localhost:8000/collections/{collection_id}/content-items"
curl -X GET "http://localhost:8000/collections/{collection_id}/content-items/{content_item_id}"
curl -X POST "http://localhost:8000/collections/{collection_id}/content-items" -H "Content-Type: application/json" -d '{"title": "My Content Item", "body": "This is my content item"}'
curl -X PUT "http://localhost:8000/collections/{collection_id}/content-items/{content_item_id}" -H "Content-Type: application/json" -d '{"title": "My Content Item", "body": "This is my content item"}'
curl -X DELETE "http://localhost:8000/collections/{collection_id}/content-items/{content_item_id}"