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

Update ruby and bundler version #78

Merged
merged 55 commits into from
Oct 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
7ec00a5
Update ruby and bundler version
matthijsgroen Sep 25, 2024
6b94bb3
Increase ubuntu version for ruby 3.3.5 and simulation of heroku-24 stack
matthijsgroen Sep 25, 2024
e24bebf
Update setup ruby action
matthijsgroen Sep 25, 2024
5906af5
Make gems at least installable
matthijsgroen Sep 25, 2024
db5b4ee
Setup Docker configuration
matthijsgroen Sep 26, 2024
e2c8286
Setup redis for sidekiq and db:seed
matthijsgroen Sep 26, 2024
d91eb4e
Replace 'should' syntax
matthijsgroen Sep 26, 2024
c01fea2
Fix env for testing
matthijsgroen Sep 26, 2024
2b0b0a2
Setup mail username
matthijsgroen Sep 26, 2024
9d8fff8
Upgrade json gem
matthijsgroen Sep 26, 2024
7362969
Start on upgrade to Rails 6
matthijsgroen Sep 29, 2024
d51d53c
Upgrade Gems to rails 6.1
matthijsgroen Sep 30, 2024
5023d21
Fix nokogiri issue in container
matthijsgroen Sep 30, 2024
d9f9fac
Fix resolver error
matthijsgroen Sep 30, 2024
7e3cfcc
Use builtin date type
matthijsgroen Sep 30, 2024
1cfd9c1
Further upgrade ruby to prevent errors
matthijsgroen Sep 30, 2024
fa28b0e
Add manifest for sprockets
matthijsgroen Sep 30, 2024
8df5238
Disable Typed store statements
matthijsgroen Sep 30, 2024
eeb220a
add sassc gem for asset pipeline
matthijsgroen Sep 30, 2024
bb94777
prevent call to pg_dump in docker for running tests
matthijsgroen Sep 30, 2024
b4c1a60
Update local ruby to 2.7.8
matthijsgroen Sep 30, 2024
d59264c
use bash instead of sh for history functions
matthijsgroen Sep 30, 2024
faa623d
Update to postgres client 16 in container
matthijsgroen Oct 2, 2024
8ce30b9
use helper instead of add_template_helper
matthijsgroen Oct 2, 2024
d3ff44e
Upgrade rspec-rails
matthijsgroen Oct 2, 2024
976df3c
Disable graph ql guard
matthijsgroen Oct 2, 2024
1ed8f51
Fix creating goal
matthijsgroen Oct 9, 2024
281bb94
Leverage existing policy object from mutation
matthijsgroen Oct 9, 2024
043142d
Reactivate typed_store
matthijsgroen Oct 9, 2024
6915a73
Fix typos
matthijsgroen Oct 9, 2024
0307aee
Recreate Graphql Policy enforcement
matthijsgroen Oct 10, 2024
48b2ab8
Fix usage of relation for post
matthijsgroen Oct 10, 2024
09b0039
Only check wildcard rights when there is no specific field policy
matthijsgroen Oct 10, 2024
250b8d0
Fix trail to data
matthijsgroen Oct 10, 2024
210becd
Update date type
matthijsgroen Oct 10, 2024
5ac9a91
Generate resolver methods on owners
matthijsgroen Oct 10, 2024
a99845d
Remove space
matthijsgroen Oct 10, 2024
156c5be
Use `resolver_` prefix to prevent naming clashes
matthijsgroen Oct 10, 2024
6f41840
Update name for autoloading
matthijsgroen Oct 10, 2024
ab81fc5
Fix test to disconnect slack
matthijsgroen Oct 10, 2024
d583fed
Fix active record error model deprecations
matthijsgroen Oct 10, 2024
cbbb992
Migrate active storage to rails 6
matthijsgroen Oct 10, 2024
27d59fc
Update workflows
matthijsgroen Oct 10, 2024
f855752
Prefer bash over sh, since bash is more user friendly
matthijsgroen Oct 10, 2024
4b6eb6e
Merge pull request #79 from kabisa/upgrade-rails-to-6
Ashhas Oct 29, 2024
09e8a45
add redis initializer
Ashhas Oct 29, 2024
0fb96c8
Update Gemfile.lock with compatible rubygems version for Heroku-20
Ashhas Oct 29, 2024
fceab2e
downgrade ffi to support Heroku 20
Ashhas Oct 29, 2024
a63a74f
add logging to verify redis initialization
Ashhas Oct 29, 2024
c757d08
add logging comments
Ashhas Oct 29, 2024
cfa0637
remove loggers for client
Ashhas Oct 29, 2024
04f2651
remove loggers for client
Ashhas Oct 29, 2024
735584b
Disable SSL verification for Redis as per Heroku requirements
pascalw Oct 30, 2024
81a369d
Parse MAIL_ENABLE_STARTTLS_AUTO into a boolean
pascalw Oct 30, 2024
f88a366
Install Heroku CLI in GH Actions
pascalw Oct 30, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: "Install Heroku CLI"
run: curl https://cli-assets.heroku.com/install.sh | sh
- uses: akhileshns/heroku-deploy@v3.0.4
with:
heroku_api_key: ${{secrets.HEROKU_API_KEY}}
heroku_app_name: "kudo-o-matic-production"
heroku_email: "ods@kabisa.nl"
heroku_email: "ods@kabisa.nl"
68 changes: 31 additions & 37 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ name: Rails test and deploy
on:
push:
branches:
- '*'
- '*/*'
- '!master'
- "*"
- "*/*"
- "!master"
pull_request:
branches:
- '*'
- '*/*'
- '!master'
- "*"
- "*/*"
- "!master"

jobs:
test:
Expand All @@ -19,55 +19,49 @@ jobs:
POSTGRES_PASSWORD: postgres
RAILS_ENV: test

runs-on: ubuntu-latest
runs-on: ubuntu-24.04

services:
db:
image: postgres:10.2
ports:
- 5432:5432
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5

steps:
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1.68.0
with:
ruby-version: 2.5.4
- uses: actions/cache@v1
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- name: Bundle install
run: |
sudo apt-get -yqq install libpq-dev
gem install bundler -v 2.3.26
bundle config path vendor/bundle
bundle install --jobs=3 --retry=3 --without production
- name: Setup environment and database
run: |
cp env.example .env
cp config/database.yml.ci config/database.yml
bundle exec rails db:create
bundle exec rails db:migrate
- name: Run tests
run: |
bundle exec rspec
- uses: actions/checkout@v2

- name: Install dependencies
run: sudo apt-get update && sudo apt-get install -y libmagickwand-dev imagemagick

- uses: ruby/setup-ruby@v1
with:
bundler-cache: true

- name: Setup environment and database
run: |
cp env.example .env
cp config/database.yml.ci config/database.yml
bundle exec rails db:create
bundle exec rails db:migrate
- name: Run tests
run: |
bundle exec rspec

deploy-staging:
if: ${{ github.ref == 'refs/heads/develop' }}
if: ${{ github.ref == 'refs/heads/update-heroku-stack' }}
needs: test
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v2
- name: "Install Heroku CLI"
run: curl https://cli-assets.heroku.com/install.sh | sh
- uses: akhileshns/heroku-deploy@v3.12.13
with:
heroku_api_key: ${{secrets.HEROKU_API_KEY}}
heroku_app_name: "kudo-o-matic-staging"
heroku_email: "ods@kabisa.nl"
heroku_email: "ods@kabisa.nl"
5 changes: 1 addition & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,11 @@
*.log
/tmp

# Configuration
config/database.yml

# User data exports
/exports
dockerfiles/development/db/data

*.swp
.*
!/.gitignore

/public/system/*
Expand Down
1 change: 0 additions & 1 deletion .ruby-version

This file was deleted.

1 change: 1 addition & 0 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ruby 2.7.8
82 changes: 33 additions & 49 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,60 +1,60 @@

# frozen_string_literal: true

source 'https://rubygems.org'

ruby '2.5.4'
ruby '2.7.8'

gem "activerecord-typedstore", "~> 1.1.1"
gem "actionpack", "~> 5.2", ">= 5.2.1"
gem "activerecord-typedstore", "~> 1.6"
gem "acts_as_votable", "~> 0.10.0"
gem "autoprefixer-rails", "~> 9.3", ">= 9.3.1"
gem "autoprefixer-rails", "~> 10.4", ">= 10.4.7.0"
gem 'aws-sdk-s3', '~> 1.67', '>= 1.67', require: false
gem "chronic", "~> 0.10.2"
gem "coffee-rails", "~> 4.2", ">= 4.2.2"
gem "devise", "~> 4.7.1"
gem "devise", "~> 4.8"
gem 'devise-async', '~> 1.0'
gem "doorkeeper", "~> 4.3"
gem "delayed_paperclip", "~> 3.0.1"
gem "daemons"
gem "draper", "~> 3.0", ">= 3.0.1"
gem "draper", "~> 4.0", ">= 4.0.2"
gem "fcm", "~> 0.0.2"
gem 'file_validators', '~> 2.3'
gem "friendly_id", "~> 5.2.4"
gem "google-id-token", "~> 1.4"
gem "graphql", "~> 1.8", ">= 1.8.10"
gem "graphql-batch", "~> 0.3.10"
gem 'graphql-guard', '~> 1.2', '>= 1.2.1'
gem 'graphql_playground-rails', '~> 2.0', '>= 2.0.1'
gem "haml-rails", "~> 1.0"
gem "graphql", "~> 1.10"
gem "graphql-batch", "~> 0.6.0"
# gem 'graphql-guard', '~> 2.0', '>= 2.0.0'
gem 'graphql-playground', "0.1.2"
gem "haml-rails", "~> 2.1"
gem "jbuilder", "~> 2.0"
gem 'json', '~> 2.7', '>= 2.7.2'
gem "json_web_token", "~> 0.3.5"
gem "loofah", "~> 2.3.1"
gem 'mini_magick', '~> 4.9', '>= 4.9.2'
gem "nokogiri", "~> 1.10.8"
gem "nokogiri", "~> 1.13.0"
gem "paperclip", "~> 6.1"
gem "pg", "~> 0.18"
gem "premailer-rails", "~> 1.9.7"
gem "puma", "~> 3.12"
gem "pg", "~> 1.5"
gem "premailer-rails", "~> 1.10"
gem "puma", "~> 5.0"
gem "rabl", "~> 0.13.1"
gem "rack-cors", "~> 1.0.5"
gem "rails", "~> 5.2", ">= 5.2.1"
gem "rails-controller-testing", "~> 1.0.2"
gem "rails-html-sanitizer", "~> 1.0.4"
gem "rails", "~> 6.1"
gem "rails-controller-testing", "~> 1.0.5"
gem "rails-html-sanitizer", "~> 1.2.0"
gem "rails_autolink", "~> 1.1.6"
gem "railties", "~> 5.2", ">= 5.2.1"
gem 'rmagick', '~> 2.16'
gem "rubocop", "~> 0.60.0", require: false
gem 'rmagick', '~> 5.3.0'
gem "rubocop", "~> 0.83.0", require: false
gem "rubyzip", "~> 1.3.0", require: "zip"
gem "sentry-raven"
gem "settingslogic", "~> 2.0", ">= 2.0.9"
gem "scss_lint", "~> 0.54", require: false
gem 'sidekiq', '~> 5.2', '>= 5.2.3'
gem 'sidekiq', '~> 6.0'
gem 'slack-ruby-client', '~> 0.14.6'
gem 'apollo_upload_server', '2.0.5'
gem 'image_processing'
gem 'apollo_upload_server', '~> 2.1.0'
gem 'image_processing', '1.12.2'
gem 'ffi', '~> 1.14.2'

group :development, :staging, :test do
# GraphQL UI similar to GraphiQL but better
gem 'database_cleaner', '~> 1.7'
gem 'faker', '~> 1.9', '>= 1.9.1'
end
Expand All @@ -63,33 +63,17 @@ group :development, :test do
gem 'dotenv-rails', '~> 2.5'
gem 'factory_bot_rails', '~> 4.8', '>= 4.8.2'
gem 'graphlient', '~> 0.3.3'
gem 'pry', '~> 0.11.3'
end

group :test do
gem 'rubocop-rspec', '~> 1.30'
gem 'rspec-rails', '~> 3.8'
gem 'rspec-graphql_matchers', '~> 0.7.1'
gem 'shoulda-matchers', '~> 3.1', '>= 3.1.2'
gem 'simplecov', '~> 0.16.1', require: false
gem 'listen', '~> 3.2'
gem 'pry', '~> 0.13'
gem 'pry-rails'
gem 'rspec-rails', '~> 4.0'
gem 'shoulda-matchers', '~> 5.3'
gem 'simplecov', '~> 0.16.1'
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
gem 'timecop', '~> 0.9.1'
end

group :development do
# Access an IRB console on exception pages or by using <%= console %> anywhere in the code.
gem 'web-console', '>= 3.3.0'
gem 'listen', '~> 3.0.5'
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
# Pry as rails console
gem 'pry-rails'

gem 'rails-erd'
gem 'railroady'
end

group :production do
gem 'rails_12factor', '~> 0.0.3'
end

Loading
Loading