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

Docker development environment improvements #5735

Merged
merged 3 commits into from
May 3, 2024
Merged
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
9 changes: 5 additions & 4 deletions .dockerdev/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ARG RUBY_VERSION
FROM ruby:$RUBY_VERSION-slim-buster
FROM ruby:$RUBY_VERSION-slim-bookworm

ARG PG_VERSION
ARG MYSQL_VERSION
Expand All @@ -14,6 +14,7 @@ RUN apt-get update -qq \
git \
imagemagick \
libvips \
libffi-dev \
libmariadb-dev \
sqlite3 \
libsqlite3-dev \
Expand All @@ -22,10 +23,10 @@ RUN apt-get update -qq \
&& rm -rf /var/cache/apt/lists/*

RUN curl -sSL https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - \
&& echo 'deb http://apt.postgresql.org/pub/repos/apt/ buster-pgdg main' $PG_VERSION > /etc/apt/sources.list.d/pgdg.list
&& echo 'deb http://apt.postgresql.org/pub/repos/apt/ bookworm-pgdg main' $PG_VERSION > /etc/apt/sources.list.d/pgdg.list

RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 467b942d3a79bd29 \
&& echo "deb http://repo.mysql.com/apt/debian/ buster mysql-"$MYSQL_VERSION > /etc/apt/sources.list.d/mysql.list
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys B7B3B788A8D3785C \
&& echo "deb http://repo.mysql.com/apt/debian/ bookworm mysql-"$MYSQL_VERSION > /etc/apt/sources.list.d/mysql.list

RUN curl -sSL https://deb.nodesource.com/setup_$NODE_VERSION.x | bash -

Expand Down
1 change: 0 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ group :backend do
gem 'capybara', '~> 3.13', require: false
gem 'capybara-screenshot', '>= 1.0.18', require: false
gem 'selenium-webdriver', require: false
gem 'webdrivers', require: false

# JavaScript testing
gem 'teaspoon', require: false
Expand Down
1 change: 0 additions & 1 deletion admin/spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
require "capybara/rspec"
require 'capybara-screenshot/rspec'
require "selenium/webdriver"
require 'webdrivers'
Capybara.save_path = ENV['CIRCLE_ARTIFACTS'] if ENV['CIRCLE_ARTIFACTS']
Capybara.exact = true
Capybara.disable_animation = true
Expand Down
1 change: 0 additions & 1 deletion backend/spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@
Capybara.exact = true

require "selenium/webdriver"
require 'webdrivers'

Capybara.register_driver :selenium_chrome_headless do |app|
browser_options = ::Selenium::WebDriver::Chrome::Options.new
Expand Down
1 change: 0 additions & 1 deletion backend/spec/teaspoon_env.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
ENV['RAILS_ENV'] = 'test'

require 'teaspoon/driver/selenium'
require 'webdrivers'

# Similar to setup described in
# https://github.com/jejacks0n/teaspoon/wiki/Micro-Applications
Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ services:
- postgres:/var/lib/postgresql/data:cached

app:
shm_size: '256mb'
build:
context: .dockerdev
dockerfile: Dockerfile
Expand Down
Loading