Skip to content

Repository files navigation

Requirements

  • docker, git, curl (7.67+), openssl, jq
  • see requirements.txt for python dependencies
  • Dockerfile is a very thin Dev Enviroment

Usage

Docker setup

cd gpbuilder-api/
bash bin/docker/setup # setup env, certs, userdata; check deps
bash bin/docker/build # build docker system
bash bin/docker/start # start docker

# bash bin/docker/stop when finished.

bash bin/fast_start [-f] performs the above, essentially.

Test API

Ensure the docker system has been setup, built and is up before running the scripts below:

bash bin/api/create_api_key <any-username>
bash tests/submit_test_gp.sh <api-key-from-response>

See hooks/pre-push for a practical usage example of the API. Also see and bin/sys_utils/run_all_tests and the tests/*.sh scripts.

Other Notes

  • Be sure to save your API_KEY, it will be permanently lost if you lose it.
  • Remove -k from curl requests in production, as it skips certificate validation. It's only used in development to allow self-signed certs. TODO: Let's Encrypt certbot
  • Ensure you are at the gpbuilder-api root when running any bin scripts
  • see localhost/openapi.json for API schema

About

minimal FastAPI gpBuilder service

Resources

Stars

0 stars

Watchers

4 watching

Forks

Releases

Packages

Contributors

Languages