Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Instructions on Porch Tracing setup added to Porch contributor guide #181

Merged
merged 21 commits into from
Nov 7, 2024
Merged
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
dc88cac
Add information on Porch tracing to the Porch documentation
liamfallon Nov 5, 2024
80da77e
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 5, 2024
b402240
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 5, 2024
4d6b6e9
Address review comments
liamfallon Nov 5, 2024
cc42935
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
5847caa
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
cdc3422
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
53652ef
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
9672621
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
e798887
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
b56431b
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
87224b8
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
aea85f3
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
db0f3e6
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
84e5a90
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
8734351
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
237b293
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
3c88e1c
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
04ee430
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
4fd470f
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
c67084c
Update content/en/docs/porch/contributors-guide/environment-setup.md
liamfallon Nov 6, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 71 additions & 0 deletions content/en/docs/porch/contributors-guide/environment-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,3 +179,74 @@ and running the [setup script](https://github.com/nephio-project/porch/blob/main

You can find a detailed description of the actual development process [here](dev-process.md).

## Enabling Open Telemetry/Jaeger tracing

### Enabling tracing on a Porch deployment

Follow the steps below to enable Open Telemetry/Jaeger tracing on your Porch deployment.

1. Apply the Porch *deployment.yaml* manifest for Jaeger.

```bash
kubectl apply -f https://raw.githubusercontent.com/nephio-project/porch/refs/heads/main/deployments/tracing/deployment.yaml
```

2. Add the environment variable *OTEL* to the porch-server manifest:

```bash
kubectl edit deployment -n porch-system porch-server
```

```bash
env:
- name: OTEL
value: otel://jaeger-oltp:4317
```

3. Set up port forwarding of the Jaeger http port to your local machine:

```bash
kubectl port-forward -n porch-system service/jaeger-http 16686
```

4. Open the Jaeger UI in your browser at *http://localhost:16686*

### Enable tracing on a local Porch server

Follow the steps below to enable Open Telemetry/Jaeger tracing on a porch server running locally on your machine, such as in VS Code.

1. Download the Jaeger binary tarball for your local machine architecture from [the Jaeger download page](https://www.jaegertracing.io/download/#binaries) and untar the tarball in some suitable directory.

2. Run Jaeger:

```bash
cd jaeger
./jaeger-all-in-one
```

3. Configure the Porch server to output Open Telemetry traces:

Set the *OTEL* environment variable to point at the Jaeger server

In *.vscode/launch.json*:

```bash
"env": {
...
...
"OTEL": "otel://localhost:4317",
...
...
}
```

In a shell:

```bash
export OTEL="otel://localhost:4317"
```

4. Open the Jaeger UI in your browser at *http://localhost:16686*

5. Run the Porch Server.