Skip to content

Commit f6c4053

Browse files
[email]: update ruby and dependencies to latest; move image to alpine (open-telemetry#2196)
* [email]: update ruby to latest 3.2 and move image to alpine Signed-off-by: Gerard Vanloo <gerard.vanloo@ibm.com> * [email]: update dependencies to latest Signed-off-by: Gerard Vanloo <gerard.vanloo@ibm.com> * [email]: update ruby to latest Signed-off-by: Gerard Vanloo <gerard.vanloo@ibm.com> * [chore]: update CHANGELOG Signed-off-by: Gerard Vanloo <gerard.vanloo@ibm.com> --------- Signed-off-by: Gerard Vanloo <gerard.vanloo@ibm.com> Co-authored-by: Juliano Costa <julianocosta89@outlook.com>
1 parent ccfac57 commit f6c4053

File tree

5 files changed

+239
-196
lines changed

5 files changed

+239
-196
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ the release.
2525
([#2170](https://github.com/open-telemetry/opentelemetry-demo/pull/2170))
2626
* [chore] bump dependent images
2727
([#2179](https://github.com/open-telemetry/opentelemetry-demo/pull/2179))
28+
* [email] bump ruby and dependencies to latest and switch to alpine
29+
([#2196](https://github.com/open-telemetry/opentelemetry-demo/pull/2196))
2830
* [cartservice] Upgrade OpenFeature version and change Hooks integration
2931
([#2199](https://github.com/open-telemetry/opentelemetry-demo/pull/2199))
3032

src/email/.ruby-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.2.2
1+
3.4.4

src/email/Dockerfile

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,27 @@
22
# SPDX-License-Identifier: Apache-2.0
33

44

5-
FROM ruby:3.2.2-slim AS base
5+
FROM ruby:3.4.4-alpine3.21 AS builder
66

7-
FROM base AS builder
7+
COPY ./src/email/Gemfile Gemfile
8+
COPY ./src/email/Gemfile.lock Gemfile.lock
89

9-
WORKDIR /tmp
10+
RUN apk update && \
11+
apk add make gcc musl-dev gcompat && \
12+
bundle install
1013

11-
COPY ./src/email/Gemfile ./src/email/Gemfile.lock ./
14+
FROM ruby:3.4.4-alpine3.21
1215

13-
#RUN apk update && apk add make gcc musl-dev gcompat && bundle install
14-
RUN apt-get update && apt-get install build-essential -y && bundle install
15-
FROM base AS release
16+
COPY --from=builder /usr/local/bundle/ /usr/local/bundle/
1617

1718
WORKDIR /email_server
1819

19-
COPY ./src/email/ .
20-
21-
RUN chmod 666 ./Gemfile.lock
22-
23-
COPY --from=builder /usr/local/bundle/ /usr/local/bundle/
20+
COPY ./src/email/views/ views/
2421

22+
COPY ./src/email/.ruby-version .ruby-version
23+
COPY ./src/email/Gemfile Gemfile
24+
COPY ./src/email/Gemfile.lock Gemfile.lock
25+
COPY ./src/email/email_server.rb email_server.rb
2526

2627
EXPOSE ${EMAIL_PORT}
2728
ENTRYPOINT ["bundle", "exec", "ruby", "email_server.rb"]

src/email/Gemfile

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,14 @@
22

33
source "https://rubygems.org"
44

5-
gem "net-smtp", "~> 0.3"
5+
gem "net-smtp", "~> 0.5.1"
66
gem "pony", "~> 1.13"
7-
gem "puma", "~> 6.3"
8-
gem "sinatra", "~> 3.0"
7+
gem "puma", "~> 6.6"
8+
gem "sinatra", "~> 4.1"
9+
gem "rackup", "~> 2.2"
910

10-
gem "opentelemetry-sdk", "~> 1.4.1"
11-
gem "opentelemetry-exporter-otlp", "~> 0.26.3"
12-
gem "opentelemetry-instrumentation-all", "~> 0.60.0"
11+
gem "google-protobuf", "~> 4.31.0"
12+
13+
gem "opentelemetry-sdk", "~> 1.8"
14+
gem "opentelemetry-exporter-otlp", "~> 0.30.0"
15+
gem "opentelemetry-instrumentation-all", "~> 0.76.0"

0 commit comments

Comments
 (0)