Skip to content

Commit f599ebc

Browse files
authored
Update patch version in docs and yaml files for v2.9.4 (#11760)
**What this PR does / why we need it**: Ran recently introduced tag updater `tools/release_update_tags.sh` (#10646) to update version tags in docs and yaml files
1 parent ddee543 commit f599ebc

File tree

15 files changed

+63
-27
lines changed

15 files changed

+63
-27
lines changed

docs/sources/get-started/deployment-modes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ For release 2.9 the components are:
7878
TIP: You can see the complete list of targets for your version of Loki by running Loki with the flag `-list-targets`, for example:
7979

8080
```bash
81-
docker run docker.io/grafana/loki:2.9.2 -config.file=/etc/loki/local-config.yaml -list-targets
81+
docker run docker.io/grafana/loki:2.9.4 -config.file=/etc/loki/local-config.yaml -list-targets
8282
```
8383
![Microservices mode diagram](../microservices-mode.png "Microservices mode")
8484

docs/sources/operations/loki-canary/_index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ Loki Canary is also provided as a Docker container image:
132132

133133
```bash
134134
# change tag to the most recent release
135-
$ docker pull grafana/loki-canary:2.0.0
135+
$ docker pull grafana/loki-canary:2.9.4
136136
```
137137

138138
### Kubernetes

docs/sources/send-data/docker-driver/_index.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ The Docker plugin must be installed on each Docker host that will be running con
2929
Run the following command to install the plugin, updating the release version if needed:
3030

3131
```bash
32-
docker plugin install grafana/loki-docker-driver:2.9.1 --alias loki --grant-all-permissions
32+
docker plugin install grafana/loki-docker-driver:2.9.4 --alias loki --grant-all-permissions
3333
```
3434

3535
To check installed plugins, use the `docker plugin ls` command. Plugins that
@@ -50,7 +50,7 @@ re-enabling and restarting Docker:
5050

5151
```bash
5252
docker plugin disable loki --force
53-
docker plugin upgrade loki grafana/loki-docker-driver:2.9.1 --grant-all-permissions
53+
docker plugin upgrade loki grafana/loki-docker-driver:2.9.4 --grant-all-permissions
5454
docker plugin enable loki
5555
systemctl restart docker
5656
```

docs/sources/send-data/promtail/installation.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Every Grafana Loki release includes binaries for Promtail which can be found on
2121

2222
```bash
2323
# modify tag to most recent version
24-
docker pull grafana/promtail:2.0.0
24+
docker pull grafana/promtail:2.9.4
2525
```
2626

2727
## Install using Helm

docs/sources/setup/install/docker.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ The configuration acquired with these installation instructions run Loki as a si
2525
Copy and paste the commands below into your command line.
2626

2727
```bash
28-
wget https://raw.githubusercontent.com/grafana/loki/v2.9.1/cmd/loki/loki-local-config.yaml -O loki-config.yaml
29-
docker run --name loki -d -v $(pwd):/mnt/config -p 3100:3100 grafana/loki:2.9.1 -config.file=/mnt/config/loki-config.yaml
30-
wget https://raw.githubusercontent.com/grafana/loki/v2.9.1/clients/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
31-
docker run --name promtail -d -v $(pwd):/mnt/config -v /var/log:/var/log --link loki grafana/promtail:2.9.1 -config.file=/mnt/config/promtail-config.yaml
28+
wget https://raw.githubusercontent.com/grafana/loki/v2.9.4/cmd/loki/loki-local-config.yaml -O loki-config.yaml
29+
docker run --name loki -d -v $(pwd):/mnt/config -p 3100:3100 grafana/loki:2.9.4 -config.file=/mnt/config/loki-config.yaml
30+
wget https://raw.githubusercontent.com/grafana/loki/v2.9.4/clients/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
31+
docker run --name promtail -d -v $(pwd):/mnt/config -v /var/log:/var/log --link loki grafana/promtail:2.9.4 -config.file=/mnt/config/promtail-config.yaml
3232
```
3333

3434
When finished, `loki-config.yaml` and `promtail-config.yaml` are downloaded in the directory you chose. Docker containers are running Loki and Promtail using those config files.
@@ -43,10 +43,10 @@ Copy and paste the commands below into your terminal. Note that you will need to
4343

4444
```bash
4545
cd "<local-path>"
46-
wget https://raw.githubusercontent.com/grafana/loki/v2.9.1/cmd/loki/loki-local-config.yaml -O loki-config.yaml
47-
docker run --name loki -v <local-path>:/mnt/config -p 3100:3100 grafana/loki:2.9.1 --config.file=/mnt/config/loki-config.yaml
48-
wget https://raw.githubusercontent.com/grafana/loki/v2.9.1/clients/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
49-
docker run -v <local-path>:/mnt/config -v /var/log:/var/log --link loki grafana/promtail:2.9.1 --config.file=/mnt/config/promtail-config.yaml
46+
wget https://raw.githubusercontent.com/grafana/loki/v2.9.4/cmd/loki/loki-local-config.yaml -O loki-config.yaml
47+
docker run --name loki -v <local-path>:/mnt/config -p 3100:3100 grafana/loki:2.9.4 --config.file=/mnt/config/loki-config.yaml
48+
wget https://raw.githubusercontent.com/grafana/loki/v2.9.4/clients/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
49+
docker run -v <local-path>:/mnt/config -v /var/log:/var/log --link loki grafana/promtail:2.9.4 --config.file=/mnt/config/promtail-config.yaml
5050
```
5151

5252
When finished, `loki-config.yaml` and `promtail-config.yaml` are downloaded in the directory you chose. Docker containers are running Loki and Promtail using those config files.
@@ -58,6 +58,6 @@ Navigate to http://localhost:3100/metrics to view the output.
5858
Run the following commands in your command line. They work for Windows or Linux systems.
5959

6060
```bash
61-
wget https://raw.githubusercontent.com/grafana/loki/v2.9.1/production/docker-compose.yaml -O docker-compose.yaml
61+
wget https://raw.githubusercontent.com/grafana/loki/v2.9.4/production/docker-compose.yaml -O docker-compose.yaml
6262
docker-compose -f docker-compose.yaml up
6363
```

docs/sources/setup/install/local.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ The configuration specifies running Loki as a single binary.
3737
**Note:** Do not download LogCLI or Loki Canary at this time. `LogCLI` allows you to run Loki queries in a command line interface. [Loki Canary]({{< relref "../../operations/loki-canary" >}}) is a tool to audit Loki performance.
3838
4. Unzip the package contents into the same directory. This is where the two programs will run.
3939
5. In the command line, change directory (`cd` on most systems) to the directory with Loki and Promtail. Copy and paste the commands below into your command line to download generic configuration files.
40-
**Note:** Use the corresponding Git refs that match your downloaded Loki version to get the correct configuration file. For example, if you are using Loki version 2.6.1, you need to use the `https://raw.githubusercontent.com/grafana/loki/v2.6.1/cmd/loki/loki-local-config.yaml` URL to download the configuration file that corresponds to the Loki version you aim to run.
40+
**Note:** Use the corresponding Git refs that match your downloaded Loki version to get the correct configuration file. For example, if you are using Loki version 2.6.1, you need to use the `https://raw.githubusercontent.com/grafana/loki/v2.9.4/cmd/loki/loki-local-config.yaml` URL to download the configuration file that corresponds to the Loki version you aim to run.
4141
4242
```
4343
wget https://raw.githubusercontent.com/grafana/loki/main/cmd/loki/loki-local-config.yaml

examples/getting-started/docker-compose.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ networks:
66

77
services:
88
read:
9-
image: grafana/loki:2.9.0
9+
image: grafana/loki:2.9.4
1010
command: "-config.file=/etc/loki/config.yaml -target=read"
1111
ports:
1212
- 3101:3100
@@ -27,7 +27,7 @@ services:
2727
- loki
2828

2929
write:
30-
image: grafana/loki:2.9.0
30+
image: grafana/loki:2.9.4
3131
command: "-config.file=/etc/loki/config.yaml -target=write"
3232
ports:
3333
- 3102:3100
@@ -46,7 +46,7 @@ services:
4646
<<: *loki-dns
4747

4848
promtail:
49-
image: grafana/promtail:2.9.0
49+
image: grafana/promtail:2.9.4
5050
volumes:
5151
- ./promtail-local-config.yaml:/etc/promtail/config.yaml:ro
5252
- /var/run/docker.sock:/var/run/docker.sock

production/docker-compose.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ networks:
55

66
services:
77
loki:
8-
image: grafana/loki:2.9.0
8+
image: grafana/loki:2.9.4
99
ports:
1010
- "3100:3100"
1111
command: -config.file=/etc/loki/local-config.yaml
1212
networks:
1313
- loki
1414

1515
promtail:
16-
image: grafana/promtail:2.9.0
16+
image: grafana/promtail:2.9.4
1717
volumes:
1818
- /var/log:/var/log
1919
command: -config.file=/etc/promtail/config.yml

production/docker/docker-compose.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ services:
1414
# Loki would not have permissions to create the directories.
1515
# Therefore the init container changes permissions of the mounted directory.
1616
init:
17-
image: &lokiImage grafana/loki:2.9.0
17+
image: &lokiImage grafana/loki:2.9.4
1818
user: root
1919
entrypoint:
2020
- "chown"
@@ -71,7 +71,7 @@ services:
7171
- ./loki/:/var/log/
7272

7373
promtail:
74-
image: grafana/promtail:2.9.0
74+
image: grafana/promtail:2.9.4
7575
volumes:
7676
- ./loki/:/var/log/
7777
- ./config:/etc/promtail/
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
_images+:: {
3-
loki_canary: 'grafana/loki-canary:2.9.0',
3+
loki_canary: 'grafana/loki-canary:2.9.4',
44
},
55
}

production/ksonnet/loki-simple-scalable/example/main.jsonnet

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ local k = import 'ksonnet-util/kausal.libsonnet',
88

99
loki {
1010
_images+:: {
11-
loki: 'grafana/loki:2.9.0',
11+
loki: 'grafana/loki:2.9.4',
1212
},
1313

1414
_config+:: {

production/ksonnet/loki-simple-scalable/images.libsonnet

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
_images+:: {
3-
loki: 'grafana/loki:2.9.0',
3+
loki: 'grafana/loki:2.9.4',
44

55
read: self.loki,
66
write: self.loki,

production/ksonnet/loki/images.libsonnet

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
memcached: 'memcached:1.5.17-alpine',
55
memcachedExporter: 'prom/memcached-exporter:v0.6.0',
66

7-
loki: 'grafana/loki:2.9.0',
7+
loki: 'grafana/loki:2.9.4',
88

99
distributor:: self.loki,
1010
ingester:: self.loki,

production/ksonnet/promtail/config.libsonnet

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
_images+:: {
3-
promtail: 'grafana/promtail:2.9.0',
3+
promtail: 'grafana/promtail:2.9.4',
44
},
55

66
_config+:: {

tools/release_update_tags.sh

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
#!/bin/bash
2+
3+
set -euo pipefail
4+
5+
OLD_VERSION=${LOKI_OLD_VERSION:-}
6+
NEW_VERSION=${LOKI_NEW_VERSION:-}
7+
8+
if [[ -z "${OLD_VERSION}" ]]
9+
then
10+
OLD_VERSION="[0-9]+\.[0-9]+\.[0-9]+"
11+
fi
12+
13+
if [[ -z "${NEW_VERSION}" ]]
14+
then
15+
read -rp "Enter new release version (eg 2.9.2): " NEW_VERSION
16+
fi
17+
18+
19+
LOKI_DOCKER_DRIVER_TAG="grafana\/loki-docker-driver:"
20+
LOKI_DOCUMENTS_TAG="loki\/v"
21+
LOKI_DOCKER_TAG="grafana\/loki:"
22+
LOKI_PROMTAIL_DOCKER_TAG="grafana\/promtail:"
23+
LOKI_CANARY_DOCKER_TAG="grafana\/loki-canary:"
24+
LOKI_LOGCLI_DOCKER_TAG="grafana\/logcli:"
25+
26+
echo "Updating version references to ${NEW_VERSION}"
27+
28+
# grep -Iq is to ignore non-binary files.
29+
find . -type f -not -path "./.git/*" -not -path "./vendor/*" -not -path "./operator/*" -not -path "./CHANGELOG.md" -not -path "./docs/sources/setup/upgrade/*" -exec grep -Iq . {} \; -print0\
30+
| xargs -0 sed -i '' -E \
31+
-e "s/(${LOKI_DOCKER_DRIVER_TAG})(${OLD_VERSION})/\1${NEW_VERSION}/g" \
32+
-e "s/(${LOKI_DOCUMENTS_TAG})(${OLD_VERSION})/\1${NEW_VERSION}/g" \
33+
-e "s/(${LOKI_DOCKER_TAG})(${OLD_VERSION})/\1${NEW_VERSION}/g" \
34+
-e "s/(${LOKI_PROMTAIL_DOCKER_TAG})(${OLD_VERSION})/\1${NEW_VERSION}/g" \
35+
-e "s/(${LOKI_CANARY_DOCKER_TAG})(${OLD_VERSION})/\1${NEW_VERSION}/g" \
36+
-e "s/(${LOKI_LOGCLI_DOCKER_TAG})(${OLD_VERSION})/\1${NEW_VERSION}/g"

0 commit comments

Comments
 (0)