Skip to content

Commit 7b4d216

Browse files
authored
Merge pull request #103 from DataDog/upgrade-ruby
Updated to Ruby 3.1.7
2 parents 8ab6855 + 7f63c2f commit 7b4d216

File tree

8 files changed

+57
-55
lines changed

8 files changed

+57
-55
lines changed

services/backend/Dockerfile

Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
1-
FROM ruby:3.0.3
1+
FROM ruby:3.1.7
22

33
RUN apt-get update -yq \
44
&& apt-get upgrade -yq \
5-
#ESSENTIALS
6-
&& apt-get install -y -qq --no-install-recommends build-essential curl git-core vim passwd unzip cron gcc wget netcat imagemagick postgresql-client wait-for-it \
5+
# ESSENTIALS
6+
&& apt-get install -y -qq --no-install-recommends \
7+
build-essential \
8+
gcc \
9+
git \
10+
curl \
11+
wget \
12+
netcat-traditional \
13+
imagemagick \
14+
postgresql-client \
15+
wait-for-it \
716
# INSTALL NODE
817
&& curl -sL https://deb.nodesource.com/setup_20.x | bash - \
918
&& apt-get install -y --no-install-recommends nodejs \
@@ -15,23 +24,18 @@ RUN apt-get clean -qy \
1524
&& rm -rf /var/lib/apt/lists/*
1625

1726
WORKDIR /app
18-
19-
# install specific version of bundler
20-
RUN gem install bundler -v 2.2.32
21-
2227
ARG DD_GIT_REPOSITORY_URL
2328
ARG DD_GIT_COMMIT_SHA
2429

2530
ENV BUNDLE_GEMFILE=/app/Gemfile \
26-
BUNDLE_JOBS=20 \
27-
BUNDLE_PATH=/bundle \
28-
BUNDLE_BIN=/bundle/bin \
29-
GEM_HOME=/bundle \
30-
# Default environment variables
31-
RAILS_ENV=production \
32-
REDIS_URL=redis://redis:6379/0 \
33-
DB_HOST=postgres \
34-
DB_PORT=5432 \
31+
BUNDLE_JOBS=20 \
32+
BUNDLE_BIN=/bundle/bin \
33+
GEM_HOME=/bundle \
34+
# Default environment variables
35+
RAILS_ENV=production \
36+
REDIS_URL=redis://redis:6379/0 \
37+
DB_HOST=postgres \
38+
DB_PORT=5432 \
3539
POSTGRES_PASSWORD=postgres \
3640
POSTGRES_USER=postgres \
3741
DB_POOL=25 \
@@ -50,4 +54,4 @@ RUN npm run build
5054

5155
EXPOSE 4000
5256

53-
CMD ["/bin/bash", "-c", "rm -f /app/tmp/pids/server.pid && bundle exec ddprofrb exec rails s -b 0.0.0.0 -p 4000"]
57+
CMD ["/bin/bash", "-c", "rm -f /app/tmp/pids/server.pid && bundle exec rails s -b 0.0.0.0 -p 4000"]

services/backend/Gemfile

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
source 'https://rubygems.org'
22

3-
ruby '3.0.3'
3+
ruby '3.1.7'
44

55
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
66
gem 'rails', '~> 6.1.4'
@@ -73,9 +73,6 @@ gem 'spree_auth_devise'
7373
gem 'spree_i18n', '>= 5.0'
7474
gem 'spree_dev_tools', require: false, group: %w[test development]
7575

76-
# Sentry Client
77-
gem 'sentry-raven'
78-
7976
# Rack CORS Middleware
8077
gem 'rack-cors'
8178

@@ -93,12 +90,17 @@ gem 'oj'
9390
# Fix SCSS errors with Ruby 3 on MacOS
9491
gem 'sassc', github: 'sass/sassc-ruby', group: :development
9592

93+
# Required for Ruby 3.1.7
94+
gem 'net-smtp'
95+
gem 'net-pop'
96+
gem 'net-imap'
97+
98+
# JSON log formatter
99+
gem 'lograge'
100+
96101
# monitoring
97102
gem 'datadog', '~> 2.18.0', require: 'datadog/auto_instrument'
98103
# needed for Datadog Continuous Profiler
99104
gem 'google-protobuf', '~> 4.30'
100105
# needed for runtime metrics
101106
gem 'dogstatsd-ruby', '~> 5.6', require: 'datadog/statsd'
102-
103-
# JSON log formatter
104-
gem 'lograge'

services/backend/Gemfile.lock

Lines changed: 27 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ GEM
133133
babel-source (>= 4.0, < 6)
134134
execjs (~> 2.0)
135135
bcrypt (3.1.16)
136-
bigdecimal (3.1.9)
136+
bigdecimal (3.2.2)
137137
bindex (0.8.1)
138138
bootsnap (1.10.2)
139139
msgpack (~> 1.2)
@@ -174,13 +174,14 @@ GEM
174174
activerecord (>= 5.a)
175175
database_cleaner-core (~> 2.0.0)
176176
database_cleaner-core (2.0.1)
177-
datadog (2.12.2)
178-
datadog-ruby_core_source (~> 3.4)
179-
libdatadog (~> 16.0.1.1.0)
180-
libddwaf (~> 1.18.0.0.1)
177+
datadog (2.18.0)
178+
datadog-ruby_core_source (~> 3.4, >= 3.4.1)
179+
libdatadog (~> 18.1.0.1.0)
180+
libddwaf (~> 1.24.1.0.0)
181181
logger
182182
msgpack
183183
datadog-ruby_core_source (3.4.1)
184+
date (3.4.1)
184185
devise (4.8.1)
185186
bcrypt (~> 3.0)
186187
orm_adapter (~> 0.1)
@@ -248,7 +249,7 @@ GEM
248249
globalid (1.0.0)
249250
activesupport (>= 5.0)
250251
glyphicons (1.0.2)
251-
google-protobuf (4.30.1-aarch64-linux)
252+
google-protobuf (4.31.1-x86_64-linux-gnu)
252253
bigdecimal
253254
rake (>= 13)
254255
hashdiff (1.0.1)
@@ -300,8 +301,8 @@ GEM
300301
addressable (~> 2.7)
301302
letter_opener (1.7.0)
302303
launchy (~> 2.2)
303-
libdatadog (16.0.1.1.0-aarch64-linux)
304-
libddwaf (1.18.0.0.1-aarch64-linux)
304+
libdatadog (18.1.0.1.0-x86_64-linux)
305+
libddwaf (1.24.1.0.0-x86_64-linux)
305306
ffi (~> 1.0)
306307
listen (3.7.1)
307308
rb-fsevent (~> 0.10, >= 0.10.3)
@@ -322,7 +323,6 @@ GEM
322323
method_source (1.0.0)
323324
mini_magick (4.11.0)
324325
mini_mime (1.1.2)
325-
mini_portile2 (2.8.0)
326326
minitest (5.15.0)
327327
monetize (1.12.0)
328328
money (~> 6.12)
@@ -331,9 +331,17 @@ GEM
331331
msgpack (1.4.4)
332332
multi_json (1.15.0)
333333
multipart-post (2.1.1)
334+
net-imap (0.5.9)
335+
date
336+
net-protocol
337+
net-pop (0.1.2)
338+
net-protocol
339+
net-protocol (0.2.2)
340+
timeout
341+
net-smtp (0.5.1)
342+
net-protocol
334343
nio4r (2.5.8)
335-
nokogiri (1.13.3)
336-
mini_portile2 (~> 2.8.0)
344+
nokogiri (1.13.3-x86_64-linux)
337345
racc (~> 1.4)
338346
octokit (4.22.0)
339347
faraday (>= 0.9)
@@ -639,6 +647,7 @@ GEM
639647
thor (1.2.1)
640648
tilt (2.0.10)
641649
timecop (0.9.4)
650+
timeout (0.4.3)
642651
timers (4.3.3)
643652
tinymce-rails (5.10.2)
644653
railties (>= 3.1.1)
@@ -674,22 +683,25 @@ GEM
674683
zeitwerk (2.5.3)
675684

676685
PLATFORMS
677-
ruby
686+
x86_64-linux
678687

679688
DEPENDENCIES
680689
activerecord-nulldb-adapter
681690
awesome_print
682691
aws-sdk-s3
683692
bootsnap
684693
dalli
685-
datadog (~> 2.12.2)
694+
datadog (~> 2.18.0)
686695
dogstatsd-ruby (~> 5.6)
687696
dotenv-rails (~> 2.1, >= 2.1.1)
688697
font_assets
689698
google-protobuf (~> 4.30)
690699
letter_opener
691700
listen
692701
lograge
702+
net-imap
703+
net-pop
704+
net-smtp
693705
oj
694706
pg
695707
puma
@@ -719,7 +731,7 @@ DEPENDENCIES
719731
webmock
720732

721733
RUBY VERSION
722-
ruby 3.0.3p157
734+
ruby 3.1.7
723735

724736
BUNDLED WITH
725-
2.2.32
737+
2.3.27

services/backend/app.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
"heroku-postgresql",
3333
"rediscloud",
3434
"sendgrid",
35-
"sentry",
3635
"scout"
3736
]
3837
}

services/backend/app/jobs/sentry_job.rb

Lines changed: 0 additions & 7 deletions
This file was deleted.

services/backend/app/models/.keep

Whitespace-only changes.

services/backend/config/initializers/raven.rb

Lines changed: 0 additions & 7 deletions
This file was deleted.

services/backend/config/sidekiq.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
:queues:
66
- default
77
- mailers
8-
- sentry
98
- active_storage_analysis
109
- spree_stock_location_stock_items
1110
- spree_webhooks

0 commit comments

Comments
 (0)