add more build/run info in README

This commit is contained in:
fix 2021-03-02 20:56:41 +01:00
parent 55109968f5
commit 2d70c2a1d9

View File

@ -3,6 +3,8 @@
prometheus docker build
## build
`docker-compose build`
or
```{bash}
GO_VERSION=1.16.0 # optional
PROMETHEUS_VERSION=2.25.0 # optional, will use latest available, if unset
@ -11,4 +13,11 @@ docker \
--build-arg GO_VERSION="${GO_VERSION}" \
--build-arg PROMETHEUS_VERSION="${PROMETHEUS_VERSION}" \
-t prometheus:"${PROMETHEUS_VERSION}"-local .
```
```
## run
use the provided `docker-compose.yml`:
`docker-compose up -d`
the container assumes a systemd-enabled system and logs to journald.
using `docker logs prometheus` or `docker-compose logs` still works, though.