Skip to content

Repository files navigation

Library docs

Concept docs

Generating secret for auth tokens:

openssl rand -hex 32

Building

  1. Remember to start docker:
sudo systemctl start docker
  1. build the docker image
make
  1. run the image
docker run --publish 8080:8080 --volume ./data:/myapp/data go-api

Other notes

The default address is 0.0.0.0, not localhost because docker.

When I, inevitably, would want to stop docker container and run the app straight:

docker container stop go-api

Will stop the server

docker system prune -a --volumes

Will delete all build artifacts from disk.

And, just in case, list containers:

docker container list --all

sh into a built image to inspect it

docker run -it --entrypoint sh go-api

Updating

  1. Update locally installed go version
  2. Update dependencies in go.mod
  3. Update alpine/go versions in Dockerfile
  4. Update vendored htmx version

About

my api

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages