Skip to content

Instantly share code, notes, and snippets.

View yahonda's full-sized avatar

Yasuo Honda yahonda

View GitHub Profile
$ RUBY_IMAGE=rubylang/ruby:master docker compose -f .buildkite/docker-compose.yml build base
[+] Building 270.4s (23/25)
=> [internal] load local bake definitions 0.0s
=> => reading from stdin 568B 0.0s
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 6.50kB 0.0s
=> [internal] load metadata for docker.io/rubylang/ruby:master 2.1s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [ 1/20] FROM docker.io/rubylang/ruby:master@sha256:7174ce49398bcf026e28b3946430cb253dbe1c9cc7d5 10.9s
@yahonda
yahonda / ruby31onrails.md
Last active April 1, 2026 21:11
Ruby 3.1 on Rails

Ruby 3.1 on Rails

Actions required to use Ruby 3.1.0 with Rails

Rails 7.0.Z

  • Rails 7.0.1 is compatible with Ruby 3.1.0.
  • Rails 7.0.1 addes net-smtp, net-imap and net-pop gems as Action Mailbox and Action Mailer dependency, you do not need to add them explicitly in your application Gemfile anymore.
  • thor 1.2.1 has been released. You will not see DidYouMean::SPELL_CHECKERS.merge deprecate warnings anymore.

Rails 6.1.Z

  • Use Rails 6.1.5 to support database.yml with aliases and secrets.yml with aliases.
#4 Patched PostgreSQL : NOT ENFORCED -> ENFORCED restires pg_trigger tgdeferrable and tginitdeferred value to t
```
postgres=# select version();
version
--------------------------------------------------------------------
PostgreSQL 19devel on x86_64-linux, compiled by gcc-15.2.1, 64-bit
(1 row)
#3 NOT ENFORCED -> ENFORCED resets pg_trigger tgdeferrable and tginitdeferred value to f
```
postgres=# select version();
version
-----------------------------------------------------------------------------------------------------------------------------
PostgreSQL 18.3 (Homebrew) on aarch64-apple-darwin25.2.0, compiled by Apple clang version 17.0.0 (clang-1700.6.3.2), 64-bit
(1 row)
postgres=# CREATE TABLE parent (
id INT PRIMARY KEY
#1 It should raise "ERROR: insert or update on table "child" violates foreign key constraint "child_parent_fk" but does not
```sql
postgres=# select version();
version
-----------------------------------------------------------------------------------------------------------------------------
PostgreSQL 18.3 (Homebrew) on aarch64-apple-darwin25.2.0, compiled by Apple clang version 17.0.0 (clang-1700.6.3.2), 64-bit
(1 row)
postgres=# CREATE TABLE parent (
id INTEGER PRIMARY KEY,
#2 It raises "ERROR: insert or update on table "child" violates foreign key constraint "child_parent_fk"
```
postgres=# select version();
version
-----------------------------------------------------------------------------------------------------------------------------
PostgreSQL 18.3 (Homebrew) on aarch64-apple-darwin25.2.0, compiled by Apple clang version 17.0.0 (clang-1700.6.3.2), 64-bit
(1 row)
postgres=# CREATE TABLE parent (
$ RUBY_IMAGE=rubylang/ruby:master docker compose -f .buildkite/docker-compose.yml build base
docker tag buildkite-base buildkite_base
[+] Building 585.2s (27/27) FINISHED
=> [internal] load local bake definitions 0.0s
=> => reading from stdin 610B 0.0s
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 6.72kB 0.0s
=> [internal] load metadata for docker.io/rubylang/ruby:master 2.3s
=> [auth] rubylang/ruby:pull token for registry-1.docker.io 0.0s
=> [internal] load .dockerignore
$ RUBY_IMAGE=ruby:3.4 docker compose -f .buildkite/docker-compose.yml build base
docker tag buildkite-base buildkite_base
[+] Building 403.2s (27/27) FINISHED
=> [internal] load local bake definitions 0.0s
=> => reading from stdin 598B 0.0s
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 6.72kB 0.0s
=> [internal] load metadata for docker.io/library/ruby:3.4 2.5s
=> [auth] library/ruby:pull token for registry-1.docker.io 0.0s
=> [internal] load .dockerignore
@yahonda
yahonda / gist:304a82326fd65f6ef5450edacf76ab97
Created December 8, 2025 06:58
Not installing bundler
```
% RUBY_IMAGE=rubylang/ruby:master docker compose -f .buildkite/docker-compose.yml build --pull base
docker tag buildkite-base buildkite_base
CI=1 docker compose -f .buildkite/docker-compose.yml run -e PRE_STEPS -e RACK --rm railties runner railties 'rake test'
[+] Building 243.8s (26/26) FINISHED
=> [internal] load local bake definitions 0.0s
=> => reading from stdin 632B 0.0s
=> [internal] load build
~/src/github.com/rails/rails % RUBY_IMAGE=rubylang/ruby:master docker compose -f .buildkite/docker-compose.yml build --pull base
docker tag buildkite-base buildkite_base
CI=1 docker compose -f .buildkite/docker-compose.yml run -e PRE_STEPS -e RACK --rm railties runner railties 'rake test'
[+] Building 543.5s (26/26) FINISHED
=> [internal] load local bake definitions 0.0s
=> => reading from stdin 632B 0.0s