Skip to content

Commit

Permalink
applied Jay's suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
tonypowa committed Aug 29, 2024
1 parent bca1868 commit b2f590f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 24 deletions.
24 changes: 6 additions & 18 deletions grafana/alerting-loki-logs/step1.md
Original file line number Diff line number Diff line change
@@ -1,30 +1,18 @@
# Before you begin

## Grafana Cloud users

As a Grafana Cloud user, you don’t have to install anything.

## Grafana OSS users

In order to run a Grafana stack locally, ensure you have the following applications installed.

- [Docker Compose](https://docs.docker.com/get-docker/) (included in Docker for Desktop for macOS and Windows)

- [Git](https://git-scm.com/)

To demonstrate the observation of data using the Grafana stack, download the files to your local machine.

1. Download and save a Docker compose file to run Grafana, Loki and Promtail.

```bash
wget https://raw.githubusercontent.com/grafana/loki/v2.8.0/production/docker-compose.yaml -O docker-compose.yaml
```{{exec}}
```bash
wget https://raw.githubusercontent.com/grafana/loki/v2.8.0/production/docker-compose.yaml -O docker-compose.yaml
```{{exec}}
1. Run the Grafana stack.
```bash
docker-compose up -d
```{{exec}}
```bash
docker-compose up -d
```{{exec}}
The first time you run `docker-compose up -d`{{copy}}, Docker downloads all the necessary resources for the tutorial. This might take a few minutes, depending on your internet connection.
Expand Down
12 changes: 6 additions & 6 deletions grafana/alerting-loki-logs/step2.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@

1. Download and save a python file that generates logs.

```bash
wget https://raw.githubusercontent.com/grafana/tutorial-environment/master/app/loki/web-server-logs-simulator.py
```{{exec}}
```bash
wget https://raw.githubusercontent.com/grafana/tutorial-environment/master/app/loki/web-server-logs-simulator.py
```{{exec}}
1. Execute the log-generating Python script.
```bash
python3 ./web-server-logs-simulator.py | sudo tee -a /var/log/web_requests.log
```{{exec}}
```bash
python3 ./web-server-logs-simulator.py | sudo tee -a /var/log/web_requests.log
```{{exec}}
## Troubleshooting the script
Expand Down

0 comments on commit b2f590f

Please sign in to comment.