From 96bf8f67be324642334169005b4375799b8d2bd7 Mon Sep 17 00:00:00 2001 From: Waldo Fouche Date: Tue, 25 Jan 2022 15:49:28 +0800 Subject: [PATCH 01/11] Update puma to 5.5.2 --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 97ab393a..f229a884 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -192,7 +192,7 @@ GEM coderay (~> 1.1) method_source (~> 1.0) public_suffix (4.0.6) - puma (5.5.1) + puma (5.5.2) nio4r (~> 2.0) racc (1.5.2) rack (2.2.3) From 65c680d2779e1c72d511918eb7ae615f4a62edf0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Feb 2022 21:50:04 +0000 Subject: [PATCH 02/11] Bump puma from 5.5.2 to 5.6.2 Bumps [puma](https://github.com/puma/puma) from 5.5.2 to 5.6.2. - [Release notes](https://github.com/puma/puma/releases) - [Changelog](https://github.com/puma/puma/blob/master/History.md) - [Commits](https://github.com/puma/puma/compare/v5.5.2...v5.6.2) --- updated-dependencies: - dependency-name: puma dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index f229a884..76cbeb2d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -192,7 +192,7 @@ GEM coderay (~> 1.1) method_source (~> 1.0) public_suffix (4.0.6) - puma (5.5.2) + puma (5.6.2) nio4r (~> 2.0) racc (1.5.2) rack (2.2.3) From d3ac707b403feb7f1e7fcb0a525f72d420c0a354 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 26 Feb 2022 02:12:22 +0000 Subject: [PATCH 03/11] Bump nokogiri from 1.12.5 to 1.13.3 Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.12.5 to 1.13.3. - [Release notes](https://github.com/sparklemotion/nokogiri/releases) - [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md) - [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.12.5...v1.13.3) --- updated-dependencies: - dependency-name: nokogiri dependency-type: indirect ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 76cbeb2d..a62be134 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -168,15 +168,15 @@ GEM marcel (1.0.1) method_source (1.0.0) mini_mime (1.1.0) - mini_portile2 (2.6.1) + mini_portile2 (2.8.0) minitest (5.14.4) mysql2 (0.5.3) nenv (0.3.0) nio4r (2.5.8) - nokogiri (1.12.5) - mini_portile2 (~> 2.6.1) + nokogiri (1.13.3) + mini_portile2 (~> 2.8.0) racc (~> 1.4) - nokogiri (1.12.5-x86_64-darwin) + nokogiri (1.13.3-x86_64-darwin) racc (~> 1.4) notiffany (0.1.3) nenv (~> 0.1) @@ -194,7 +194,7 @@ GEM public_suffix (4.0.6) puma (5.6.2) nio4r (~> 2.0) - racc (1.5.2) + racc (1.6.0) rack (2.2.3) rack-test (1.1.0) rack (>= 1.0, < 3) From d9cfe9055f7177679dd25651c1f1baf001541150 Mon Sep 17 00:00:00 2001 From: Waldo Fouche Date: Wed, 2 Mar 2022 10:28:11 +0800 Subject: [PATCH 04/11] Upgrade to rails `6.0.4.4` (#249) * Upgrade to rails `6.1.4.4` Co-authored-by: Jun Co-authored-by: Matthew Puku --- Gemfile | 2 +- Gemfile.lock | 238 ++++++++++-------- app/controllers/api/api_controller.rb | 2 +- app/jobs/process_incoming_f_ticks_events.rb | 2 +- bin/setup | 48 ++-- config/application.rb | 2 + config/environment.rb | 4 +- config/environments/development.rb | 46 +++- config/environments/production.rb | 77 +++++- config/environments/test.rb | 23 +- config/initializers/app_config.rb | 4 +- config/initializers/backtrace_silencers.rb | 7 + config/initializers/cookies_serializer.rb | 4 + .../initializers/filter_parameter_logging.rb | 3 + db/schema.rb | 10 +- spec/factories/api_subject.rb | 2 +- spec/factories/automated_report.rb | 4 +- spec/factories/jwt.rb | 8 +- spec/factories/saml_attribute.rb | 2 +- spec/factories/subject.rb | 2 +- 20 files changed, 333 insertions(+), 157 deletions(-) diff --git a/Gemfile b/Gemfile index 7ca0a4dc..f7eda04f 100644 --- a/Gemfile +++ b/Gemfile @@ -2,7 +2,7 @@ source 'https://rubygems.org' -gem 'rails', '>= 5', '< 6' +gem 'rails', '6.0.4.4' gem 'sass-rails' gem 'jbuilder' diff --git a/Gemfile.lock b/Gemfile.lock index a62be134..0d286186 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,70 +11,84 @@ GEM tilt will_paginate accession (1.0.0) - actioncable (5.2.6) - actionpack (= 5.2.6) + actioncable (6.0.4.4) + actionpack (= 6.0.4.4) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailer (5.2.6) - actionpack (= 5.2.6) - actionview (= 5.2.6) - activejob (= 5.2.6) + actionmailbox (6.0.4.4) + actionpack (= 6.0.4.4) + activejob (= 6.0.4.4) + activerecord (= 6.0.4.4) + activestorage (= 6.0.4.4) + activesupport (= 6.0.4.4) + mail (>= 2.7.1) + actionmailer (6.0.4.4) + actionpack (= 6.0.4.4) + actionview (= 6.0.4.4) + activejob (= 6.0.4.4) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 2.0) - actionpack (5.2.6) - actionview (= 5.2.6) - activesupport (= 5.2.6) + actionpack (6.0.4.4) + actionview (= 6.0.4.4) + activesupport (= 6.0.4.4) rack (~> 2.0, >= 2.0.8) rack-test (>= 0.6.3) rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.0, >= 1.0.2) - actionview (5.2.6) - activesupport (= 5.2.6) + rails-html-sanitizer (~> 1.0, >= 1.2.0) + actiontext (6.0.4.4) + actionpack (= 6.0.4.4) + activerecord (= 6.0.4.4) + activestorage (= 6.0.4.4) + activesupport (= 6.0.4.4) + nokogiri (>= 1.8.5) + actionview (6.0.4.4) + activesupport (= 6.0.4.4) builder (~> 3.1) erubi (~> 1.4) rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.0, >= 1.0.3) - activejob (5.2.6) - activesupport (= 5.2.6) + rails-html-sanitizer (~> 1.1, >= 1.2.0) + activejob (6.0.4.4) + activesupport (= 6.0.4.4) globalid (>= 0.3.6) - activemodel (5.2.6) - activesupport (= 5.2.6) - activerecord (5.2.6) - activemodel (= 5.2.6) - activesupport (= 5.2.6) - arel (>= 9.0) - activestorage (5.2.6) - actionpack (= 5.2.6) - activerecord (= 5.2.6) + activemodel (6.0.4.4) + activesupport (= 6.0.4.4) + activerecord (6.0.4.4) + activemodel (= 6.0.4.4) + activesupport (= 6.0.4.4) + activestorage (6.0.4.4) + actionpack (= 6.0.4.4) + activejob (= 6.0.4.4) + activerecord (= 6.0.4.4) marcel (~> 1.0.0) - activesupport (5.2.6) + activesupport (6.0.4.4) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 0.7, < 2) minitest (~> 5.1) tzinfo (~> 1.1) + zeitwerk (~> 2.2, >= 2.2.2) addressable (2.8.0) public_suffix (>= 2.0.2, < 5.0) aes_key_wrap (1.1.0) - arel (9.0.0) ast (2.4.2) aws-eventstream (1.2.0) - aws-partitions (1.523.0) - aws-sdk-core (3.121.6) + aws-partitions (1.560.0) + aws-sdk-core (3.127.0) aws-eventstream (~> 1, >= 1.0.2) - aws-partitions (~> 1, >= 1.520.1) + aws-partitions (~> 1, >= 1.525.0) aws-sigv4 (~> 1.1) jmespath (~> 1.0) - aws-sdk-sqs (1.44.0) - aws-sdk-core (~> 3, >= 3.120.0) + aws-sdk-sqs (1.51.0) + aws-sdk-core (~> 3, >= 3.127.0) aws-sigv4 (~> 1.1) aws-sigv4 (1.4.0) aws-eventstream (~> 1, >= 1.0.2) bindata (2.4.10) - brakeman (5.1.1) + brakeman (5.2.1) builder (3.2.4) byebug (11.1.3) - capybara (3.35.3) + capybara (3.36.0) addressable + matrix mini_mime (>= 0.1.3) nokogiri (~> 1.8) rack (>= 1.6.0) @@ -93,23 +107,23 @@ GEM activerecord (>= 5.a) database_cleaner-core (~> 2.0.0) database_cleaner-core (2.0.1) - diff-lcs (1.4.4) + diff-lcs (1.5.0) docile (1.4.0) erubi (1.10.0) erubis (2.7.0) - execjs (2.7.0) + execjs (2.8.1) factory_bot (4.11.1) activesupport (>= 3.0.0) factory_bot_rails (4.11.1) factory_bot (~> 4.11.1) railties (>= 3.0.0) - faker (2.18.0) + faker (2.19.0) i18n (>= 1.6, < 2) fakeredis (0.8.0) redis (~> 4.1) - ffi (1.15.3) - formatador (0.3.0) - globalid (0.5.2) + ffi (1.15.5) + formatador (1.1.0) + globalid (1.0.0) activesupport (>= 5.0) god (0.13.7) guard (2.18.0) @@ -134,18 +148,19 @@ GEM guard (~> 2.1) guard-compat (~> 1.1) rspec (>= 2.99.0, < 4.0) - guard-rubocop (1.4.0) + guard-rubocop (1.5.0) guard (~> 2.0) rubocop (< 2.0) guard-unicorn (0.2.0) guard (>= 1.1) hashdiff (1.0.1) - i18n (1.8.10) + i18n (1.10.0) concurrent-ruby (~> 1.0) implicit-schema (0.0.1) - jbuilder (2.11.2) + jbuilder (2.11.5) + actionview (>= 5.0.0) activesupport (>= 5.0.0) - jmespath (1.4.0) + jmespath (1.6.0) json-jwt (1.13.0) activesupport (>= 4.2) aes_key_wrap @@ -156,33 +171,30 @@ GEM launchy (2.5.0) addressable (~> 2.7) libv8 (3.16.14.19) - listen (3.6.0) + listen (3.7.1) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) - loofah (2.12.0) + loofah (2.14.0) crass (~> 1.0.2) nokogiri (>= 1.5.9) lumberjack (1.2.8) mail (2.7.1) mini_mime (>= 0.1.1) - marcel (1.0.1) + marcel (1.0.2) + matrix (0.4.2) method_source (1.0.0) - mini_mime (1.1.0) - mini_portile2 (2.8.0) - minitest (5.14.4) + mini_mime (1.1.2) + minitest (5.15.0) mysql2 (0.5.3) nenv (0.3.0) nio4r (2.5.8) - nokogiri (1.13.3) - mini_portile2 (~> 2.8.0) - racc (~> 1.4) nokogiri (1.13.3-x86_64-darwin) racc (~> 1.4) notiffany (0.1.3) nenv (~> 0.1) shellany (~> 0.0) - parallel (1.20.1) - parser (3.0.2.0) + parallel (1.21.0) + parser (3.1.1.0) ast (~> 2.4.1) poltergeist (1.18.1) capybara (>= 2.1, < 4) @@ -198,18 +210,20 @@ GEM rack (2.2.3) rack-test (1.1.0) rack (>= 1.0, < 3) - rails (5.2.6) - actioncable (= 5.2.6) - actionmailer (= 5.2.6) - actionpack (= 5.2.6) - actionview (= 5.2.6) - activejob (= 5.2.6) - activemodel (= 5.2.6) - activerecord (= 5.2.6) - activestorage (= 5.2.6) - activesupport (= 5.2.6) + rails (6.0.4.4) + actioncable (= 6.0.4.4) + actionmailbox (= 6.0.4.4) + actionmailer (= 6.0.4.4) + actionpack (= 6.0.4.4) + actiontext (= 6.0.4.4) + actionview (= 6.0.4.4) + activejob (= 6.0.4.4) + activemodel (= 6.0.4.4) + activerecord (= 6.0.4.4) + activestorage (= 6.0.4.4) + activesupport (= 6.0.4.4) bundler (>= 1.3.0) - railties (= 5.2.6) + railties (= 6.0.4.4) sprockets-rails (>= 2.0.0) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) @@ -218,56 +232,56 @@ GEM rails-dom-testing (2.0.3) activesupport (>= 4.2.0) nokogiri (>= 1.6) - rails-html-sanitizer (1.3.0) + rails-html-sanitizer (1.4.2) loofah (~> 2.3) - railties (5.2.6) - actionpack (= 5.2.6) - activesupport (= 5.2.6) + railties (6.0.4.4) + actionpack (= 6.0.4.4) + activesupport (= 6.0.4.4) method_source rake (>= 0.8.7) - thor (>= 0.19.0, < 2.0) - rainbow (3.0.0) - raindrops (0.19.2) + thor (>= 0.20.3, < 2.0) + rainbow (3.1.1) + raindrops (0.20.0) rake (13.0.6) rapid-rack (0.3.0) json-jwt - rb-fsevent (0.11.0) + rb-fsevent (0.11.1) rb-inotify (0.10.1) ffi (~> 1.0) - redis (4.4.0) - redis-actionpack (5.2.0) - actionpack (>= 5, < 7) + redis (4.6.0) + redis-actionpack (5.3.0) + actionpack (>= 5, < 8) redis-rack (>= 2.1.0, < 3) redis-store (>= 1.1.0, < 2) - redis-activesupport (5.2.1) - activesupport (>= 3, < 7) + redis-activesupport (5.3.0) + activesupport (>= 3, < 8) redis-store (>= 1.3, < 2) - redis-rack (2.1.3) + redis-rack (2.1.4) rack (>= 2.0.8, < 3) redis-store (>= 1.2, < 2) redis-rails (5.0.2) redis-actionpack (>= 5.0, < 6) redis-activesupport (>= 5.0, < 6) redis-store (>= 1.2, < 2) - redis-store (1.9.0) + redis-store (1.9.1) redis (>= 4, < 5) ref (2.0.0) - regexp_parser (2.1.1) + regexp_parser (2.2.1) rexml (3.2.5) rmagick (2.16.0) - rspec (3.10.0) - rspec-core (~> 3.10.0) - rspec-expectations (~> 3.10.0) - rspec-mocks (~> 3.10.0) - rspec-core (3.10.1) - rspec-support (~> 3.10.0) - rspec-expectations (3.10.1) + rspec (3.11.0) + rspec-core (~> 3.11.0) + rspec-expectations (~> 3.11.0) + rspec-mocks (~> 3.11.0) + rspec-core (3.11.0) + rspec-support (~> 3.11.0) + rspec-expectations (3.11.0) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.10.0) - rspec-mocks (3.10.2) + rspec-support (~> 3.11.0) + rspec-mocks (3.11.0) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.10.0) - rspec-rails (5.0.2) + rspec-support (~> 3.11.0) + rspec-rails (5.1.0) actionpack (>= 5.2) activesupport (>= 5.2) railties (>= 5.2) @@ -275,22 +289,24 @@ GEM rspec-expectations (~> 3.10) rspec-mocks (~> 3.10) rspec-support (~> 3.10) - rspec-support (3.10.2) - rubocop (1.19.0) + rspec-support (3.11.0) + rubocop (1.25.1) parallel (~> 1.10) - parser (>= 3.0.0.0) + parser (>= 3.1.0.0) rainbow (>= 2.2.2, < 4.0) regexp_parser (>= 1.8, < 3.0) rexml - rubocop-ast (>= 1.9.1, < 2.0) + rubocop-ast (>= 1.15.1, < 2.0) ruby-progressbar (~> 1.7) unicode-display_width (>= 1.4.0, < 3.0) - rubocop-ast (1.10.0) - parser (>= 3.0.1.1) - rubocop-rails (2.11.3) + rubocop-ast (1.16.0) + parser (>= 3.1.1.0) + rubocop-rails (2.13.2) activesupport (>= 4.2.0) rack (>= 1.1) rubocop (>= 1.7.0, < 2.0) + rubocop-rspec (2.9.0) + rubocop (~> 1.19) ruby-progressbar (1.11.0) sass-rails (6.0.0) sassc-rails (~> 2.1, >= 2.1.1) @@ -303,30 +319,30 @@ GEM sprockets-rails tilt shellany (0.0.1) - shoulda-matchers (5.0.0) + shoulda-matchers (5.1.0) activesupport (>= 5.2.0) simplecov (0.21.2) docile (~> 1.1) simplecov-html (~> 0.11) simplecov_json_formatter (~> 0.1) simplecov-html (0.12.3) - simplecov_json_formatter (0.1.3) + simplecov_json_formatter (0.1.4) slim (4.1.0) temple (>= 0.7.6, < 0.9) tilt (>= 2.0.6, < 2.1) sprockets (3.7.2) concurrent-ruby (~> 1.0) rack (> 1, < 3) - sprockets-rails (3.2.2) - actionpack (>= 4.0) - activesupport (>= 4.0) + sprockets-rails (3.4.2) + actionpack (>= 5.2) + activesupport (>= 5.2) sprockets (>= 3.0.0) temple (0.8.2) terminal-notifier-guard (1.7.0) therubyracer (0.12.3) libv8 (~> 3.16.14.15) ref - thor (1.1.0) + thor (1.2.1) thread_safe (0.3.6) tilt (2.0.10) timecop (0.9.4) @@ -339,8 +355,8 @@ GEM thread_safe (~> 0.1) uglifier (4.2.0) execjs (>= 0.3.0, < 3) - unicode-display_width (2.0.0) - unicorn (6.0.0) + unicode-display_width (2.1.0) + unicorn (6.1.0) kgio (~> 2.6) raindrops (~> 0.7) valhammer (1.0.0) @@ -356,10 +372,9 @@ GEM will_paginate (3.3.1) xpath (3.2.0) nokogiri (~> 1.8) + zeitwerk (2.5.4) PLATFORMS - ruby - x86_64-darwin-19 x86_64-darwin-20 DEPENDENCIES @@ -389,7 +404,7 @@ DEPENDENCIES poltergeist pry puma - rails (>= 5, < 6) + rails (= 6.0.4.4) rails-controller-testing rapid-rack redis @@ -398,6 +413,7 @@ DEPENDENCIES rspec-rails rubocop rubocop-rails + rubocop-rspec (~> 2.9) sass-rails shoulda-matchers simplecov @@ -412,4 +428,4 @@ DEPENDENCIES webmock BUNDLED WITH - 2.1.4 + 2.2.26 diff --git a/app/controllers/api/api_controller.rb b/app/controllers/api/api_controller.rb index 56371811..53397361 100644 --- a/app/controllers/api/api_controller.rb +++ b/app/controllers/api/api_controller.rb @@ -38,7 +38,7 @@ def x509_cn x509_dn_parsed = OpenSSL::X509::Name.parse(x509_dn) x509_dn_hash = - x509_dn_parsed.to_a.map { |components| components[0..1] }.to_h + x509_dn_parsed.to_a.to_h { |components| components[0..1] } x509_dn_hash['CN'] || raise(Unauthorized, 'Subject CN invalid') rescue OpenSSL::X509::NameError diff --git a/app/jobs/process_incoming_f_ticks_events.rb b/app/jobs/process_incoming_f_ticks_events.rb index df4f9021..cba7dfd3 100644 --- a/app/jobs/process_incoming_f_ticks_events.rb +++ b/app/jobs/process_incoming_f_ticks_events.rb @@ -4,7 +4,7 @@ class ProcessIncomingFTicksEvents def perform FederatedLoginEvent.transaction do incoming_events.find_each do |event| - create_instance(event) && event.destroy! || event.discard! + (create_instance(event) && event.destroy!) || event.discard! end end end diff --git a/bin/setup b/bin/setup index c30bb534..75b2f149 100755 --- a/bin/setup +++ b/bin/setup @@ -1,27 +1,39 @@ #!/usr/bin/env ruby -# frozen_string_literal: true +require 'fileutils' +require 'gumboot/strap' -Dir.chdir File.expand_path('..', File.dirname(__FILE__)) +include Gumboot::Strap -puts '== Installing dependencies ==' -system 'gem install bundler --conservative' -system 'bundle check || bundle install' -system 'bundle exec torba pack' -require 'bundler/setup' -require 'gumboot/strap' +# path to your application root. +APP_ROOT = File.expand_path('..', __dir__) -include Gumboot::Strap +def system!(*args) + system(*args) || abort("\n== Command #{args} failed ==") +end -puts "\n== Installing configuration files ==" -link_global_configuration %w[rapidconnect.yml api-client.crt api-client.key +FileUtils.chdir APP_ROOT do + # This script is a way to setup or update your development environment automatically. + # This script is idempotent, so that you can run it at anytime and get an expectable outcome. + # Add necessary setup steps to this file. + + puts '== Installing dependencies ==' + system! 'gem install bundler --conservative' + system('bundle check') || system!('bundle install') + system 'bundle exec torba pack' + + + puts "\n== Installing configuration files ==" + link_global_configuration %w[rapidconnect.yml api-client.crt api-client.key event_encryption_key.pem] -update_local_configuration %w[reporting_service.yml] + update_local_configuration %w[reporting_service.yml] + + puts "\n== Preparing database ==" + system! 'bin/rails db:prepare' -puts "\n== Loading Rails environment ==" -require_relative '../config/environment' + puts "\n== Removing old logs and tempfiles ==" + system! 'bin/rails log:clear tmp:clear' -ensure_activerecord_databases(%w[test development]) -maintain_activerecord_schema -clean_logs -clean_tempfiles + puts "\n== Restarting application server ==" + system! 'bin/rails restart' +end diff --git a/config/application.rb b/config/application.rb index de1c136c..70dd6e62 100644 --- a/config/application.rb +++ b/config/application.rb @@ -19,6 +19,8 @@ class Application < Rails::Application File.join(config.root, 'app', 'jobs', 'concerns') ] + config.autoloader = :zeitwerk + config.assets.precompile += %w[render_report.js] config.rapid_rack.receiver = 'Authentication::SubjectReceiver' diff --git a/config/environment.rb b/config/environment.rb index eb669856..d5abe558 100644 --- a/config/environment.rb +++ b/config/environment.rb @@ -1,5 +1,7 @@ # frozen_string_literal: true -require File.expand_path('application', __dir__) +# Load the Rails application. +require_relative 'application' +# Initialize the Rails application. Rails.application.initialize! diff --git a/config/environments/development.rb b/config/environments/development.rb index 8245998e..6b78294d 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -1,20 +1,56 @@ # frozen_string_literal: true Rails.application.configure do + # Settings specified here will take precedence over those in config/application.rb. + + # In the development environment your application's code is reloaded on + # every request. This slows down response time but is perfect for development + # since you don't have to restart the web server when you make code changes. config.cache_classes = false + # Do not eager load code on boot. config.eager_load = false - config.consider_all_requests_local = true - config.action_controller.perform_caching = false + # Show full error reports. + config.consider_all_requests_local = true + + # Enable/disable caching. By default caching is disabled. + # Run rails dev:cache to toggle caching. + if Rails.root.join('tmp', 'caching-dev.txt').exist? + config.action_controller.perform_caching = true + config.action_controller.enable_fragment_cache_logging = true - # config.action_mailer.raise_delivery_errors = false + config.cache_store = :memory_store + config.public_file_server.headers = { + 'Cache-Control' => "public, max-age=#{2.days.to_i}" + } + else + config.action_controller.perform_caching = false + config.cache_store = :null_store + end + + # Print deprecation notices to the Rails logger. config.active_support.deprecation = :log + # Raise an error on page load if there are pending migrations. config.active_record.migration_error = :page_load + # Highlight code that triggered database queries in logs. + config.active_record.verbose_query_logs = true + + # Debug mode disables concatenation and preprocessing of assets. + # This option may cause significant delays in view rendering with a large + # number of complex assets. config.assets.debug = true - config.assets.digest = true - config.assets.raise_runtime_errors = true + + # Suppress logger output for asset requests. + config.assets.quiet = true + + # Raises error for missing translations. + # config.action_view.raise_on_missing_translations = true + + # Use an evented file watcher to asynchronously detect changes in source code, + # routes, locales, etc. This feature depends on the listen gem. + config.file_watcher = ActiveSupport::EventedFileUpdateChecker end diff --git a/config/environments/production.rb b/config/environments/production.rb index 2d9cbacf..337c02bb 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -1,29 +1,104 @@ # frozen_string_literal: true Rails.application.configure do + # Settings specified here will take precedence over those in config/application.rb. + + # Code is not reloaded between requests. config.cache_classes = true + # Eager load code on boot. This eager loads most of Rails and + # your application in memory, allowing both threaded web servers + # and those relying on copy on write to perform better. + # Rake tasks automatically ignore this option for performance. config.eager_load = true + # Full error reports are disabled and caching is turned on. config.consider_all_requests_local = false config.action_controller.perform_caching = true + # Ensures that a master key has been made available in either ENV["RAILS_MASTER_KEY"] + # or in config/master.key. This key is used to decrypt credentials (and other encrypted files). + # config.require_master_key = true + + # Disable serving static files from the `/public` folder by default since + # Apache or NGINX already handles this. config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present? config.public_file_server.headers = { - 'Cache-Control' => 'public, max-age=3600' + 'Cache-Control' => "public, max-age=#{1.day.to_i}" } + # Compress CSS using a preprocessor. config.assets.js_compressor = :uglifier + + # Do not fallback to assets pipeline if a precompiled asset is missed. config.assets.compile = false config.assets.digest = true + # Enable serving of images, stylesheets, and JavaScripts from an asset server. + # config.action_controller.asset_host = 'http://assets.example.com' + + # Specifies the header that your server uses for sending files. + # config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache + # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX + + # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies. + # config.force_ssl = true + + # Use the lowest log level to ensure availability of diagnostic information + # when problems arise. config.log_level = :debug + # Prepend all log lines with the following tags. + config.log_tags = [:request_id] + + # Use a different cache store in production. + # config.cache_store = :mem_cache_store + + # Use a real queuing backend for Active Job (and separate queues per environment). + # config.active_job.queue_adapter = :resque + # config.active_job.queue_name_prefix = "reporting_service_production" + + # Enable locale fallbacks for I18n (makes lookups for any locale fall back to + # the I18n.default_locale when a translation cannot be found). config.i18n.fallbacks = true + # Send deprecation notices to registered listeners. config.active_support.deprecation = :notify + # Use default logging formatter so that PID and timestamp are not suppressed. config.log_formatter = ::Logger::Formatter.new + # Use a different logger for distributed setups. + # require 'syslog/logger' + # config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new 'app-name') + + if ENV['RAILS_LOG_TO_STDOUT'].present? + logger = ActiveSupport::Logger.new($stdout) + logger.formatter = config.log_formatter + config.logger = ActiveSupport::TaggedLogging.new(logger) + end + + # Do not dump schema after migrations. config.active_record.dump_schema_after_migration = false + + # Inserts middleware to perform automatic connection switching. + # The `database_selector` hash is used to pass options to the DatabaseSelector + # middleware. The `delay` is used to determine how long to wait after a write + # to send a subsequent read to the primary. + # + # The `database_resolver` class is used by the middleware to determine which + # database is appropriate to use based on the time delay. + # + # The `database_resolver_context` class is used by the middleware to set + # timestamps for the last write to the primary. The resolver uses the context + # class timestamps to determine how long to wait before reading from the + # replica. + # + # By default Rails will store a last write timestamp in the session. The + # DatabaseSelector middleware is designed as such you can define your own + # strategy for connection switching and pass that into the middleware through + # these configuration options. + # config.active_record.database_selector = { delay: 2.seconds } + # config.active_record.database_resolver = ActiveRecord::Middleware::DatabaseSelector::Resolver + # config.active_record.database_resolver_context = ActiveRecord::Middleware::DatabaseSelector::Resolver::Session end diff --git a/config/environments/test.rb b/config/environments/test.rb index d59b33f4..6363b294 100644 --- a/config/environments/test.rb +++ b/config/environments/test.rb @@ -1,25 +1,42 @@ # frozen_string_literal: true +# The test environment is used exclusively to run your application's +# test suite. You never need to work with it otherwise. Remember that +# your test database is "scratch space" for the test suite and is wiped +# and recreated between test runs. Don't rely on the data there! + Rails.application.configure do + # Settings specified here will take precedence over those in config/application.rb. + config.cache_classes = true + # Do not eager load code on boot. This avoids loading your whole application + # just for the purpose of running a single test. If you are using a tool that + # preloads Rails for running tests, you may have to set it to true. config.eager_load = false + # Configure public file server for tests with Cache-Control for performance. config.public_file_server.enabled = true config.public_file_server.headers = { - 'Cache-Control' => 'public, max-age=3600' + 'Cache-Control' => "public, max-age=#{1.hour.to_i}" } + # Show full error reports and disable caching. config.consider_all_requests_local = true config.action_controller.perform_caching = false + # Raise exceptions instead of rendering exception templates. config.action_dispatch.show_exceptions = false + # Disable request forgery protection in test environment. config.action_controller.allow_forgery_protection = false - config.active_support.test_order = :random - + # Print deprecation notices to the stderr. config.active_support.deprecation = :stderr + # Raises error for missing translations. + # config.action_view.raise_on_missing_translations = true + + config.active_support.test_order = :random config.rapid_rack.test_mode = true end diff --git a/config/initializers/app_config.rb b/config/initializers/app_config.rb index f4b7e06f..3315c294 100644 --- a/config/initializers/app_config.rb +++ b/config/initializers/app_config.rb @@ -2,7 +2,7 @@ require 'mail' require 'aws-sdk-sqs' - +# rubocop:disable Style/OpenStructUse Rails.application.configure do app_config_file = Rails.root.join('config', 'reporting_service.yml') app_config = YAML.safe_load(app_config_file.read) @@ -65,3 +65,5 @@ end end end + +# rubocop:enable Style/OpenStructUse diff --git a/config/initializers/backtrace_silencers.rb b/config/initializers/backtrace_silencers.rb index 8e9b8f90..d0f0d3b5 100644 --- a/config/initializers/backtrace_silencers.rb +++ b/config/initializers/backtrace_silencers.rb @@ -1 +1,8 @@ # frozen_string_literal: true +# Be sure to restart your server when you modify this file. + +# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces. +# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ } + +# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code. +# Rails.backtrace_cleaner.remove_silencers! diff --git a/config/initializers/cookies_serializer.rb b/config/initializers/cookies_serializer.rb index 22762bd0..ee8dff9c 100644 --- a/config/initializers/cookies_serializer.rb +++ b/config/initializers/cookies_serializer.rb @@ -1,3 +1,7 @@ # frozen_string_literal: true +# Be sure to restart your server when you modify this file. + +# Specify a serializer for the signed and encrypted cookie jars. +# Valid options are :json, :marshal, and :hybrid. Rails.application.config.action_dispatch.cookies_serializer = :json diff --git a/config/initializers/filter_parameter_logging.rb b/config/initializers/filter_parameter_logging.rb index e25c8cc5..7a4f47b4 100644 --- a/config/initializers/filter_parameter_logging.rb +++ b/config/initializers/filter_parameter_logging.rb @@ -1,3 +1,6 @@ # frozen_string_literal: true +# Be sure to restart your server when you modify this file. + +# Configure sensitive parameters which will be filtered from the log file. Rails.application.config.filter_parameters += [:password] diff --git a/db/schema.rb b/db/schema.rb index 33a902cd..d2a37f8f 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -2,11 +2,11 @@ # of editing this file, please use the migrations feature of Active Record to # incrementally modify your database, and then regenerate this schema definition. # -# Note that this schema.rb definition is the authoritative source for your -# database schema. If you need to create the application database on another -# system, you should be using db:schema:load, not running all the migrations -# from scratch. The latter is a flawed and unsustainable approach (the more migrations -# you'll amass, the slower it'll run and the greater likelihood for issues). +# This file is the source Rails uses to define your schema when running `rails +# db:schema:load`. When creating a new database, `rails db:schema:load` tends to +# be faster and is potentially less error prone than running all of your +# migrations from scratch. Old migrations may fail to apply correctly if those +# migrations use external dependencies or application code. # # It's strongly recommended that you check this file into your version control system. diff --git a/spec/factories/api_subject.rb b/spec/factories/api_subject.rb index ca7d507f..d73631c8 100644 --- a/spec/factories/api_subject.rb +++ b/spec/factories/api_subject.rb @@ -8,7 +8,7 @@ description { Faker::Lorem.sentence } trait :authorized do - transient { permission '*' } + transient { permission { '*' } } after(:create) do |user, attrs| role = create(:permission, value: attrs.permission).role diff --git a/spec/factories/automated_report.rb b/spec/factories/automated_report.rb index d136692c..1f8f9f2a 100644 --- a/spec/factories/automated_report.rb +++ b/spec/factories/automated_report.rb @@ -2,7 +2,7 @@ FactoryBot.define do factory :automated_report do - report_class 'FederationGrowthReport' - interval 'monthly' + report_class { 'FederationGrowthReport' } + interval { 'monthly' } end end diff --git a/spec/factories/jwt.rb b/spec/factories/jwt.rb index 4a2617cf..c5fa88ee 100644 --- a/spec/factories/jwt.rb +++ b/spec/factories/jwt.rb @@ -27,14 +27,14 @@ iat { Time.zone.now.to_i } nbf { 30.seconds.ago.to_i } exp { 30.seconds.from_now.to_i } - typ 'authnresponse' + typ { 'authnresponse' } jti { SecureRandom.hex } config = Rails.configuration.rapid_rack - iss config.issuer - aud config.audience + iss { config.issuer } + aud { config.audience } transient do - secret(config.secret) + secret { config.secret } association :aaf_attributes end diff --git a/spec/factories/saml_attribute.rb b/spec/factories/saml_attribute.rb index 1a65ccdb..e2ea3c76 100644 --- a/spec/factories/saml_attribute.rb +++ b/spec/factories/saml_attribute.rb @@ -7,7 +7,7 @@ core { false } trait :core_attribute do - core true + core { true } end end end diff --git a/spec/factories/subject.rb b/spec/factories/subject.rb index 30a3db28..4c774120 100644 --- a/spec/factories/subject.rb +++ b/spec/factories/subject.rb @@ -13,7 +13,7 @@ mail { Faker::Internet.email(name: name) } trait :authorized do - transient { permission '*' } + transient { permission { '*' } } after(:create) do |user, attrs| role = create(:permission, value: attrs.permission).role From 5debbef572bec8c6a8bf00407d3b85ed3c6d7628 Mon Sep 17 00:00:00 2001 From: Waldo Fouche Date: Thu, 3 Mar 2022 14:57:53 +0800 Subject: [PATCH 05/11] Add platform `x86_64-linux` (#252) Your bundle only supports platforms ["x86_64-darwin-20"] but your local platform is x86_64-linux Add the current platform to the lockfile with `bundle lock --add-platform x86_64-linux` and try again. --- Gemfile.lock | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 0d286186..1595cf32 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -171,6 +171,7 @@ GEM launchy (2.5.0) addressable (~> 2.7) libv8 (3.16.14.19) + libv8 (3.16.14.19-x86_64-linux) listen (3.7.1) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) @@ -190,6 +191,8 @@ GEM nio4r (2.5.8) nokogiri (1.13.3-x86_64-darwin) racc (~> 1.4) + nokogiri (1.13.3-x86_64-linux) + racc (~> 1.4) notiffany (0.1.3) nenv (~> 0.1) shellany (~> 0.0) @@ -305,8 +308,6 @@ GEM activesupport (>= 4.2.0) rack (>= 1.1) rubocop (>= 1.7.0, < 2.0) - rubocop-rspec (2.9.0) - rubocop (~> 1.19) ruby-progressbar (1.11.0) sass-rails (6.0.0) sassc-rails (~> 2.1, >= 2.1.1) @@ -376,6 +377,7 @@ GEM PLATFORMS x86_64-darwin-20 + x86_64-linux DEPENDENCIES aaf-gumboot @@ -413,7 +415,6 @@ DEPENDENCIES rspec-rails rubocop rubocop-rails - rubocop-rspec (~> 2.9) sass-rails shoulda-matchers simplecov From 7b536a6523cdddceb665d942cb6faa91ed18cb6f Mon Sep 17 00:00:00 2001 From: Waldo Fouche Date: Mon, 21 Mar 2022 09:18:25 +0800 Subject: [PATCH 06/11] Gemfile updates (#254) --- Gemfile | 3 +- Gemfile.lock | 123 ++++++++++++++++++++++++--------------------------- 2 files changed, 59 insertions(+), 67 deletions(-) diff --git a/Gemfile b/Gemfile index f7eda04f..28a19b17 100644 --- a/Gemfile +++ b/Gemfile @@ -2,13 +2,12 @@ source 'https://rubygems.org' -gem 'rails', '6.0.4.4' +gem 'rails', '<6.1' gem 'sass-rails' gem 'jbuilder' gem 'mysql2' gem 'slim' -gem 'therubyracer', require: false gem 'uglifier', require: false gem 'redis' diff --git a/Gemfile.lock b/Gemfile.lock index 1595cf32..5250ea5c 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,56 +11,56 @@ GEM tilt will_paginate accession (1.0.0) - actioncable (6.0.4.4) - actionpack (= 6.0.4.4) + actioncable (6.0.4.7) + actionpack (= 6.0.4.7) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (6.0.4.4) - actionpack (= 6.0.4.4) - activejob (= 6.0.4.4) - activerecord (= 6.0.4.4) - activestorage (= 6.0.4.4) - activesupport (= 6.0.4.4) + actionmailbox (6.0.4.7) + actionpack (= 6.0.4.7) + activejob (= 6.0.4.7) + activerecord (= 6.0.4.7) + activestorage (= 6.0.4.7) + activesupport (= 6.0.4.7) mail (>= 2.7.1) - actionmailer (6.0.4.4) - actionpack (= 6.0.4.4) - actionview (= 6.0.4.4) - activejob (= 6.0.4.4) + actionmailer (6.0.4.7) + actionpack (= 6.0.4.7) + actionview (= 6.0.4.7) + activejob (= 6.0.4.7) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 2.0) - actionpack (6.0.4.4) - actionview (= 6.0.4.4) - activesupport (= 6.0.4.4) + actionpack (6.0.4.7) + actionview (= 6.0.4.7) + activesupport (= 6.0.4.7) rack (~> 2.0, >= 2.0.8) rack-test (>= 0.6.3) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (6.0.4.4) - actionpack (= 6.0.4.4) - activerecord (= 6.0.4.4) - activestorage (= 6.0.4.4) - activesupport (= 6.0.4.4) + actiontext (6.0.4.7) + actionpack (= 6.0.4.7) + activerecord (= 6.0.4.7) + activestorage (= 6.0.4.7) + activesupport (= 6.0.4.7) nokogiri (>= 1.8.5) - actionview (6.0.4.4) - activesupport (= 6.0.4.4) + actionview (6.0.4.7) + activesupport (= 6.0.4.7) builder (~> 3.1) erubi (~> 1.4) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.1, >= 1.2.0) - activejob (6.0.4.4) - activesupport (= 6.0.4.4) + activejob (6.0.4.7) + activesupport (= 6.0.4.7) globalid (>= 0.3.6) - activemodel (6.0.4.4) - activesupport (= 6.0.4.4) - activerecord (6.0.4.4) - activemodel (= 6.0.4.4) - activesupport (= 6.0.4.4) - activestorage (6.0.4.4) - actionpack (= 6.0.4.4) - activejob (= 6.0.4.4) - activerecord (= 6.0.4.4) + activemodel (6.0.4.7) + activesupport (= 6.0.4.7) + activerecord (6.0.4.7) + activemodel (= 6.0.4.7) + activesupport (= 6.0.4.7) + activestorage (6.0.4.7) + actionpack (= 6.0.4.7) + activejob (= 6.0.4.7) + activerecord (= 6.0.4.7) marcel (~> 1.0.0) - activesupport (6.0.4.4) + activesupport (6.0.4.7) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 0.7, < 2) minitest (~> 5.1) @@ -71,8 +71,8 @@ GEM aes_key_wrap (1.1.0) ast (2.4.2) aws-eventstream (1.2.0) - aws-partitions (1.560.0) - aws-sdk-core (3.127.0) + aws-partitions (1.563.0) + aws-sdk-core (3.128.1) aws-eventstream (~> 1, >= 1.0.2) aws-partitions (~> 1, >= 1.525.0) aws-sigv4 (~> 1.1) @@ -117,8 +117,8 @@ GEM factory_bot_rails (4.11.1) factory_bot (~> 4.11.1) railties (>= 3.0.0) - faker (2.19.0) - i18n (>= 1.6, < 2) + faker (2.20.0) + i18n (>= 1.8.11, < 2) fakeredis (0.8.0) redis (~> 4.1) ffi (1.15.5) @@ -160,7 +160,7 @@ GEM jbuilder (2.11.5) actionview (>= 5.0.0) activesupport (>= 5.0.0) - jmespath (1.6.0) + jmespath (1.6.1) json-jwt (1.13.0) activesupport (>= 4.2) aes_key_wrap @@ -170,8 +170,6 @@ GEM rexml launchy (2.5.0) addressable (~> 2.7) - libv8 (3.16.14.19) - libv8 (3.16.14.19-x86_64-linux) listen (3.7.1) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) @@ -213,20 +211,20 @@ GEM rack (2.2.3) rack-test (1.1.0) rack (>= 1.0, < 3) - rails (6.0.4.4) - actioncable (= 6.0.4.4) - actionmailbox (= 6.0.4.4) - actionmailer (= 6.0.4.4) - actionpack (= 6.0.4.4) - actiontext (= 6.0.4.4) - actionview (= 6.0.4.4) - activejob (= 6.0.4.4) - activemodel (= 6.0.4.4) - activerecord (= 6.0.4.4) - activestorage (= 6.0.4.4) - activesupport (= 6.0.4.4) + rails (6.0.4.7) + actioncable (= 6.0.4.7) + actionmailbox (= 6.0.4.7) + actionmailer (= 6.0.4.7) + actionpack (= 6.0.4.7) + actiontext (= 6.0.4.7) + actionview (= 6.0.4.7) + activejob (= 6.0.4.7) + activemodel (= 6.0.4.7) + activerecord (= 6.0.4.7) + activestorage (= 6.0.4.7) + activesupport (= 6.0.4.7) bundler (>= 1.3.0) - railties (= 6.0.4.4) + railties (= 6.0.4.7) sprockets-rails (>= 2.0.0) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) @@ -237,9 +235,9 @@ GEM nokogiri (>= 1.6) rails-html-sanitizer (1.4.2) loofah (~> 2.3) - railties (6.0.4.4) - actionpack (= 6.0.4.4) - activesupport (= 6.0.4.4) + railties (6.0.4.7) + actionpack (= 6.0.4.7) + activesupport (= 6.0.4.7) method_source rake (>= 0.8.7) thor (>= 0.20.3, < 2.0) @@ -268,7 +266,6 @@ GEM redis-store (>= 1.2, < 2) redis-store (1.9.1) redis (>= 4, < 5) - ref (2.0.0) regexp_parser (2.2.1) rexml (3.2.5) rmagick (2.16.0) @@ -284,7 +281,7 @@ GEM rspec-mocks (3.11.0) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.11.0) - rspec-rails (5.1.0) + rspec-rails (5.1.1) actionpack (>= 5.2) activesupport (>= 5.2) railties (>= 5.2) @@ -340,13 +337,10 @@ GEM sprockets (>= 3.0.0) temple (0.8.2) terminal-notifier-guard (1.7.0) - therubyracer (0.12.3) - libv8 (~> 3.16.14.15) - ref thor (1.2.1) thread_safe (0.3.6) tilt (2.0.10) - timecop (0.9.4) + timecop (0.9.5) torba (1.1.0) thor (>= 0.19.1, < 2) torba-rails (1.0.2) @@ -406,7 +400,7 @@ DEPENDENCIES poltergeist pry puma - rails (= 6.0.4.4) + rails (< 6.1) rails-controller-testing rapid-rack redis @@ -420,7 +414,6 @@ DEPENDENCIES simplecov slim terminal-notifier-guard - therubyracer timecop torba-rails uglifier From 31b65d7f3b996db5e8d160cce5a0f0bd32785b84 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Apr 2022 14:11:03 +0800 Subject: [PATCH 07/11] Bump puma from 5.6.2 to 5.6.4 (#255) Bumps [puma](https://github.com/puma/puma) from 5.6.2 to 5.6.4. - [Release notes](https://github.com/puma/puma/releases) - [Changelog](https://github.com/puma/puma/blob/master/History.md) - [Commits](https://github.com/puma/puma/compare/v5.6.2...v5.6.4) --- updated-dependencies: - dependency-name: puma dependency-type: direct:development ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 5250ea5c..bb5cf5db 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -205,7 +205,7 @@ GEM coderay (~> 1.1) method_source (~> 1.0) public_suffix (4.0.6) - puma (5.6.2) + puma (5.6.4) nio4r (~> 2.0) racc (1.6.0) rack (2.2.3) From 1a9f3e01cddb30af290a3216e0ef0593601be2fb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 13 Apr 2022 08:49:51 +1000 Subject: [PATCH 08/11] Bump nokogiri from 1.13.3 to 1.13.4 (#256) Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.13.3 to 1.13.4. - [Release notes](https://github.com/sparklemotion/nokogiri/releases) - [Changelog](https://github.com/sparklemotion/nokogiri/blob/v1.13.4/CHANGELOG.md) - [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.13.3...v1.13.4) --- updated-dependencies: - dependency-name: nokogiri dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Gemfile.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index bb5cf5db..6763c297 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -187,9 +187,9 @@ GEM mysql2 (0.5.3) nenv (0.3.0) nio4r (2.5.8) - nokogiri (1.13.3-x86_64-darwin) + nokogiri (1.13.4-x86_64-darwin) racc (~> 1.4) - nokogiri (1.13.3-x86_64-linux) + nokogiri (1.13.4-x86_64-linux) racc (~> 1.4) notiffany (0.1.3) nenv (~> 0.1) From 3f33c70c9ae1d3782e8297f58c44b9aa0e973158 Mon Sep 17 00:00:00 2001 From: Waldo Fouche Date: Thu, 19 May 2022 09:07:17 +0800 Subject: [PATCH 09/11] fix: mysqld_safe: command not found (#258) --- buildspec.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/buildspec.yml b/buildspec.yml index 1365d0c0..643645b6 100644 --- a/buildspec.yml +++ b/buildspec.yml @@ -8,7 +8,7 @@ phases: - echo 'export LC_ALL=en_US.UTF-8' >> ~/.bashrc - echo 'export AAF_DEV=1' >> ~/.bashrc - - mysqld_safe & disown -h + - mysqld --user=root & disown -h - sleep 5 - mysql -e "grant all privileges on *.* to 'reporting_app'@'%' identified by 'password';" From 8c7fb1ea1a3c0080328190a51944fe2af5f4a08d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 30 May 2022 08:32:54 +1000 Subject: [PATCH 10/11] Bump rack from 2.2.3 to 2.2.3.1 (#260) Bumps [rack](https://github.com/rack/rack) from 2.2.3 to 2.2.3.1. - [Release notes](https://github.com/rack/rack/releases) - [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md) - [Commits](https://github.com/rack/rack/compare/2.2.3...2.2.3.1) --- updated-dependencies: - dependency-name: rack dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 6763c297..cb6550c6 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -208,7 +208,7 @@ GEM puma (5.6.4) nio4r (~> 2.0) racc (1.6.0) - rack (2.2.3) + rack (2.2.3.1) rack-test (1.1.0) rack (>= 1.0, < 3) rails (6.0.4.7) From de861b645529f5db1e72843442d157e57c03622c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 Jun 2022 09:37:44 +1000 Subject: [PATCH 11/11] Bump nokogiri from 1.13.4 to 1.13.6 (#259) Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.13.4 to 1.13.6. - [Release notes](https://github.com/sparklemotion/nokogiri/releases) - [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md) - [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.13.4...v1.13.6) --- updated-dependencies: - dependency-name: nokogiri dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Gemfile.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index cb6550c6..ccb33fff 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -187,9 +187,9 @@ GEM mysql2 (0.5.3) nenv (0.3.0) nio4r (2.5.8) - nokogiri (1.13.4-x86_64-darwin) + nokogiri (1.13.6-x86_64-darwin) racc (~> 1.4) - nokogiri (1.13.4-x86_64-linux) + nokogiri (1.13.6-x86_64-linux) racc (~> 1.4) notiffany (0.1.3) nenv (~> 0.1)