haul

command module
v0.74.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 6, 2023 License: GPL-2.0 Imports: 9 Imported by: 0

README

haul

Inventory management system for patchwork assets.

warning

This project is under heavy development, AND in a pre-release state.

Please do not use in production, as there is no guaranteed stability with the API or the database at this moment.

API specification

OpenAPI3 spec

prerequisites

To build and deploy the server:

  • docker

  • docker-compose

To build the client:

  • go

procedure

Prepare .env file for database deployment informations (replace haul in production)

# .env
HAUL_POSTGRES_DATABASE=haul
HAUL_POSTGRES_PASSWORD=haul
HAUL_POSTGRES_USER=haul

Deploy haul database and server

$ docker-compose up -d --build

Make sure the server is up

$ docker-compose logs haul

optional - local cli

Haul is accessed mainly through its API.

Install the cli locally.

$ go install

Then, add a config locally to $HOME/.haul.yaml (based on the Config struct in ./models/config.go), or specify a different config location with the --config flag.

Note that if you installed the server from docker-compose without any modifications (not suited for production), you should only need to set client.api.host

Once that is done, make sure you can access the server with a healthcheck

$ haul ping

Alternatively, you can query GET /v1/health http/1.1 (requires key authentication by default, which is silly)

See $ haul help for more options

Documentation

Overview

Copyright © 2023 The Haul Authors

Inventory management system for patchwork assets.

Directories

Path Synopsis
Package apihandler defines haul's v1 API endpoint logic
Package apihandler defines haul's v1 API endpoint logic
Package apiresponse defines haul's API response types
Package apiresponse defines haul's API response types
Package cli provides a client SDK for outputting data to a terminal in multiple formats
Package cli provides a client SDK for outputting data to a terminal in multiple formats
cmd
Package cmd implements cli (cobra/viper) commands for the application.
Package cmd implements cli (cobra/viper) commands for the application.
asset
Package assetcmd provides commands for manipulating assets
Package assetcmd provides commands for manipulating assets
asset/attribute
Package assetattributecmd provides commands for manipulating asset attribute
Package assetattributecmd provides commands for manipulating asset attribute
asset/description
Package assetdescriptioncmd provides commands for manipulating asset descriptions
Package assetdescriptioncmd provides commands for manipulating asset descriptions
asset/status
Package assetstatuscmd provides commands for manipulating asset status
Package assetstatuscmd provides commands for manipulating asset status
asset/target
Package assettargetcmd provides commands for manipulating asset targets
Package assettargetcmd provides commands for manipulating asset targets
attribute
Package attributecmd provides commands for manipulating attributes
Package attributecmd provides commands for manipulating attributes
attribute/asset
Package attributeassetcmd provides commands for manipulating asset attribute
Package attributeassetcmd provides commands for manipulating asset attribute
event
Package eventcmd provides commands for manipulating events
Package eventcmd provides commands for manipulating events
Package db provides mechanisms for interacting with a database directly
Package db provides mechanisms for interacting with a database directly
Package models provides the object models for haul requests and responses
Package models provides the object models for haul requests and responses

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL