coderookieerick/bureaucrat

By coderookieerick

Updated 10 months ago

A lightweight experimental credential-less service with queues, tables, blobs, and trees

Image
Message queues
Databases & storage
0

2.4K

coderookieerick/bureaucrat repository overview

Bureaucrat

NuGet version (Bureaucrat.Core) Docker image (bureaucrat) Pypi package (pybureaucrat) Nightly builds

A lightweight experimental credential-less service with queues, tables, blobs, trees and templates built on top of FastApi.

Admin site

In the hosting machine you can access the admin site in this location: http://localhost:19970/

Queues

Bureacrat uses a very straightfoward in-memory queue paradigm. Every queue gets created when needed (when any queue or dequeue operation is requested in a queue). Futhermore every queue can be deleted on demand.

methodpathname
GET/queues/Lists every queue
GET/queues/{name}Dequeues from the {name} queue
POST/queues/{name}Enqueues in the {name} queue
DELETE/queues/{name}Deletes the {name} queue

Blobs

The blob service consists in a simple plain storage. The name given to any blob is purely logic. The physical location for every blob is set by the BUREAUCRAT_BLOBS_ROOT environment variable, which should point to an existing writable folder.

methodpathname
GET/blobs/{full_path}Get the index of the logic {full_path} location
GET/blobs/download:{full_path}Downloads the blob in the logic {full_path} location
GET/blobs/raw:{full_path}Gets the content of the blob in the logic {full_path} location as a base64 string
POST/blobs/{full_path}Writes a file in the logic {full_path} location
DELETE/blobs/{full_path}Deletes the file in the logic {full_path} location

Tables

This service is just a backend for sqlite3 databases. The root path for every database is set by the BUREAUCRAT_TABLES_DATABASE environment variable, which should point to an existing writable folder.

methodpathname
GET/tables/List every database
GET/tables/{database}List every table in the {database}
POST/tables/{database}Executes in the {database} the query sent in the body and returns the result
GET/tables/{database}/{table}Retrieves every record in the {table} in the {database}

Trees

The trees service is just a bunch of folders with some json files. Folders are called forests and json files are called trees. You can freely navigate and update any tree inside any forest. The physical location for the root of every forest is set in the BUREAUCRAT_TREES_ROOT environment variable, which should point to an existing writable folder.

methodpathname
GET/trees/List every available forest
GET/trees/{forest}Lists every available tree in the {forest}
GET/trees/{forest}/{tree}/index:{path}Gets the index for the node located in the {path} inside the {tree} belonging to the specified {forest}
GET/trees/{forest}/{tree}/{path}Gets the content of the node located in the {path} inside the {tree} belonging to the specified {forest}
POST/trees/{forest}/{tree}/{path}Sets the content of the node located in the {path} inside the {tree} belonging to the specified {forest}

Templates

The templates service allows you to manage documents templates, and parse and export them. The supported parsing engines include mako and jinja2. Also, you can export to pdf or docx.

methodpathname
GET/templates/templateList every available template
GET/trees/renderLists every available render
GET/trees/parserLists every available parser
GET/templates/template/{template}Gets the content of the template {template}
POST/templates/template/{template}Sets the content of the template {template}, creating it if not exists
DELETE/templates/template/{template}Deletes the template {template}
PUT/templates/template/{template}?render={render}&parser={parser}Parses the template {template} with the given data, using the render {render} and {parser} parser.

dev.moradev.dev

Tag summary

Content type

Image

Digest

sha256:fe38c60e0

Size

479.1 MB

Last updated

10 months ago

docker pull coderookieerick/bureaucrat:linux-x64