Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
10 changes: 6 additions & 4 deletions .env
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,13 @@ FRONTEND_PORT=8080
FRONTEND_ADDR=frontend:${FRONTEND_PORT}
FRONTEND_DOCKERFILE=./src/frontend/Dockerfile

# Frontend Proxy (Envoy)
# Frontend Proxy (NGINX)
FRONTEND_HOST=frontend
ENVOY_PORT=8080
FRONTEND_PROXY_ADDR=frontend-proxy:${ENVOY_PORT}
FRONTEND_PROXY_DOCKERFILE=./src/frontend-proxy/Dockerfile
NGINX_PORT=8080
FRONTEND_PROXY_ADDR=frontend-proxy:${NGINX_PORT}
# FRONTEND_PROXY_DOCKERFILE=./src/frontend-proxy/Dockerfile #Default NGINX Proxy
FRONTEND_PROXY_DOCKERFILE=./src/nginx-frontend-proxy/Dockerfile # Customs NGINX Proxy OTEL Instrumented


# Image Provider
IMAGE_PROVIDER_HOST=image-provider
Expand Down
55 changes: 1 addition & 54 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,54 +1 @@
*~
*.iml
*.ipr
*.iws
*.pyc
.nb-gradle
.nb-gradle-properties
.swp
.DS_Store
\#*\#

docker-compose.override.yml

# Eclipse
.classpath
.project
.settings

bin/
obj/
.vs/
.vscode
.gradle/
.idea/
build/
node_modules/
coverage
.next/
out/
build
next-env.d.ts
vendor/
composer.lock
.venv
.dockerhub.env
.ghcr.env

src/frontend/cypress/videos
src/frontend/cypress/screenshots
src/shipping/target/
test/tracetesting/tracetesting-vars.yaml

# Ignore copied/generated protobuf files
/src/accounting/src/protos/
/src/cart/src/protos/
/src/fraud-detection/src/main/proto
/src/payment/demo.proto
/src/shipping/proto/
/src/currency/proto

# Android
*.apk

!src/currency/build
license.jwt
40 changes: 16 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,23 @@
[![Artifact Hub](https://img.shields.io/endpoint?url=https://artifacthub.io/badge/repository/opentelemetry-demo)](https://artifacthub.io/packages/helm/opentelemetry-helm/opentelemetry-demo)
[![OpenSSF Best Practices](https://www.bestpractices.dev/projects/9247/badge)](https://www.bestpractices.dev/en/projects/9247)

## Welcome to the OpenTelemetry Astronomy Shop Demo
## Welcome to the OpenTelemetry Astronomy Shop Demo with NGINX Proxy
This is simple copy of the OpenTelemetry demo quickly hacked to replace the envoy proxy with nginx proxy. Everything else stays the same.
To run NGINX Open Source, simply issue the following command :
```shell
$ cd src/nginx-frontend-proxy/
$ cp Dockerfil.oss Dockerfile
```
To run NGINX+, you must get a valid license (trial) in the form of a 'license.jwt' file. Then issue the following commands :
```shell
$ cd src/nginx-frontend-proxy/
$ cp Dockerfil.nplus Dockerfile
```
Now to build the frontend-proxy image with NGINX, issue the following:
```shell
$ docker build -f src/nginx-frontend-proxy/Dockerfile -t latest-frontend-proxy .
```

This repository contains the OpenTelemetry Astronomy Shop, a microservice-based
distributed system intended to illustrate the implementation of OpenTelemetry in
a near real-world environment.

Our goals are threefold:

- Provide a realistic example of a distributed system that can be used to
demonstrate OpenTelemetry instrumentation and observability.
- Build a base for vendors, tooling authors, and others to extend and
demonstrate their OpenTelemetry integrations.
- Create a living example for OpenTelemetry contributors to use for testing new
versions of the API, SDK, and other components or enhancements.

We've already made [huge
progress](https://github.com/open-telemetry/opentelemetry-demo/blob/main/CHANGELOG.md),
and development is ongoing. We hope to represent the full feature set of
OpenTelemetry across its languages in the future.

If you'd like to help (**which we would love**), check out our [contributing
guidance](./CONTRIBUTING.md).

If you'd like to extend this demo or maintain a fork of it, read our
[fork guidance](https://opentelemetry.io/docs/demo/forking/).

## Quick start

Expand Down
14 changes: 8 additions & 6 deletions docker-compose.minimal.yml
Original file line number Diff line number Diff line change
Expand Up @@ -242,20 +242,22 @@ services:
condition: service_started
logging: *logging

# Frontend Proxy (Envoy)
# Frontend Proxy (NGINX)
frontend-proxy:
image: ${IMAGE_NAME}:${DEMO_VERSION}-frontend-proxy
image: ${DEMO_VERSION}-frontend-proxy
# image: frontend-proxy #NGINX Configuration
container_name: frontend-proxy
build:
context: ./
dockerfile: ${FRONTEND_PROXY_DOCKERFILE}
dockerfile: ${FRONTEND_PROXY_DOCKERFILE} # NGINX
# dockerfile: ./src/nginx-frontend-proxy/Dockerfile # nginx
deploy:
resources:
limits:
memory: 65M
restart: unless-stopped
ports:
- "${ENVOY_PORT}:${ENVOY_PORT}"
- "${NGINX_PORT}:${NGINX_PORT}"
- 10000:10000
environment:
- FRONTEND_PORT
Expand All @@ -273,7 +275,7 @@ services:
- OTEL_COLLECTOR_PORT_HTTP
- OTEL_RESOURCE_ATTRIBUTES
- OTEL_SERVICE_NAME=frontend-proxy
- ENVOY_PORT
- NGINX_PORT
- FLAGD_HOST
- FLAGD_PORT
- FLAGD_UI_HOST
Expand Down Expand Up @@ -616,7 +618,7 @@ services:
condition: service_healthy
logging: *logging
environment:
- ENVOY_PORT
- NGINX_PORT
- HOST_FILESYSTEM
- OTEL_COLLECTOR_HOST
- OTEL_COLLECTOR_PORT_GRPC
Expand Down
11 changes: 7 additions & 4 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -318,18 +318,21 @@ services:

# Frontend Proxy (Envoy)
frontend-proxy:
image: ${IMAGE_NAME}:${DEMO_VERSION}-frontend-proxy
# image: ${IMAGE_NAME}:${DEMO_VERSION}-frontend-proxy # Default Envoy Proxy
image: ${DEMO_VERSION}-frontend-proxy
# image: frontend-proxy #NGINX Version of the proxy
container_name: frontend-proxy
build:
context: ./
dockerfile: ${FRONTEND_PROXY_DOCKERFILE}
# dockerfile: ./src/nginx-frontend-proxy/Dockerfile #NGINX Proxy instead of Envoy
deploy:
resources:
limits:
memory: 65M
restart: unless-stopped
ports:
- "${ENVOY_PORT}:${ENVOY_PORT}"
- "${NGINX_PORT}:${NGINX_PORT}"
- 10000:10000
environment:
- FRONTEND_PORT
Expand All @@ -347,7 +350,7 @@ services:
- OTEL_COLLECTOR_PORT_HTTP
- OTEL_RESOURCE_ATTRIBUTES
- OTEL_SERVICE_NAME=frontend-proxy
- ENVOY_PORT
- NGINX_PORT
- FLAGD_HOST
- FLAGD_PORT
- FLAGD_UI_HOST
Expand Down Expand Up @@ -762,7 +765,7 @@ services:
condition: service_healthy
logging: *logging
environment:
- ENVOY_PORT
- NGINX_PORT
- HOST_FILESYSTEM
- OTEL_COLLECTOR_HOST
- OTEL_COLLECTOR_PORT_GRPC
Expand Down
6 changes: 3 additions & 3 deletions src/email/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

source "https://rubygems.org"

gem "net-smtp", "~> 0.3"
gem "net-smtp", "~> 0.5"
gem "pony", "~> 1.13"
gem "puma", "~> 6.3"
gem "sinatra", "~> 3.0"
gem "puma", "~> 7.0"
gem "sinatra", "~> 4.1"

gem "opentelemetry-sdk", "~> 1.4.1"
gem "opentelemetry-exporter-otlp", "~> 0.26.3"
Expand Down
Loading