Files
routewatch/.dockerignore
T
clawbot 6f0134bf5d
check / check (push) Waiting to run
Stamp the git tag or short commit in a plain docker build (closes #46)
A plain `docker build .` stamped `unknown` into the page footer:
.dockerignore left out .git, and the Dockerfile built without the -X
flags. The context now carries .git without .git/config, which can hold
a credential. The build stage takes the VERSION build argument when one
is given, otherwise `git describe --tags --always`, fails the build if
.git is present and no version comes out, and stamps it together with
the full commit the footer links to. `make build` now uses
`git describe` as well, and script/docker is the current shared copy.

Model: opus-5-5
2026-10-02 04:14:50 +00:00

33 lines
966 B
Plaintext

# Docker does not read .gitignore, and a pattern here matches from the root of
# the build context only: a pattern meant for every directory needs `**/`.
# .git is sent without its config. Without a VERSION build argument the
# stage that compiles runs `git describe --tags --always` on .git, which
# does not need .git/config; that file can hold a credential, such as a
# password in a remote URL or the token the CI checkout step stores there.
.git/config
# Local build and debug output: `make build`, `make run`, `make asupdate`, test
# binaries, coverage profiles and source archives.
/bin
/log.txt
/out
/pkg/asinfo/asdata.json
**/*.tar.zst
**/*.test
**/*.out
**/*.tmp
# Local databases and secrets. The image carries a source archive of the whole
# build context, so these would otherwise ship inside it.
**/*.db
**/*.db-journal
**/*.db-wal
**/.env
# A local Go workspace points at directories outside the build context.
/go.work
/go.work.sum
**/.DS_Store