-
Open this directory in your terminal.
-
Install the project dependencies using the following command:
mix deps.get
- Run the docker-compose file to start the Postgres database:
docker-compose up -d --build
-
Obtain the OTLP Auth Header from the Last9 dashboard. The Auth header is required in the next steps.
-
Next, run the commands below to set the environment variables.
export OTEL_SERVICE_NAME=phoenix-app-service
export OTEL_EXPORTER_OTLP_ENDPOINT=https://otlp.last9.io
export OTEL_EXPORTER_OTLP_AUTH_HEADER="Basic <BASIC_AUTH_HEADER>"
- Run the Phoenix application:
mix phx.server
-
Once the server is running, you can access the application at
http://localhost:4000
by default. You can go to the/users
route to start interacting with the application. -
Go to the Last9 dashboard to view the traces.