Skip to content

[Bug] - ruby3.4-rubygem-bundler do not create /usr/bin/bundle #1073

@koshigoe

Description

@koshigoe

Describe the bug
The /usr/bin/bundle does not exist.

To Reproduce

$ docker run --rm -it public.ecr.aws/amazonlinux/amazonlinux:2023.10.20260302.1

bash-5.2# dnf info ruby3.4
Last metadata expiration check: 0:00:16 ago on Thu Mar 12 06:11:42 2026.
Available Packages
Name         : ruby3.4
Version      : 3.4.8
Release      : 27.amzn2023.0.2
Architecture : aarch64
Size         : 41 k
Source       : ruby3.4-3.4.8-27.amzn2023.0.2.src.rpm
Repository   : amazonlinux
Summary      : An interpreter of object-oriented scripting language
URL          : https://www.ruby-lang.org/
License      : (Ruby OR BSD-2-Clause) AND (Ruby OR BSD-2-Clause OR GPL-1.0-or-later) AND BSD-3-Clause AND (GPL-3.0-or-later WITH Bison-exception-2.2) AND ISC AND
             : LicenseRef-Fedora-Public-Domain AND MIT AND CC0 AND zlib AND Unicode-DFS-2015 AND HPND-Markus-Kuhn AND Ruby-pty
Description  : Ruby is the interpreted scripting language for quick and easy
             : object-oriented programming.  It has many features to process text
             : files and to do system management tasks (as in Perl).  It is simple,
             : straight-forward, and extensible.

bash-5.2# dnf info ruby3.4-rubygem-bundler
Last metadata expiration check: 0:01:52 ago on Thu Mar 12 06:11:42 2026.
Available Packages
Name         : ruby3.4-rubygem-bundler
Version      : 2.6.9
Release      : 27.amzn2023.0.2
Architecture : noarch
Size         : 413 k
Source       : ruby3.4-3.4.8-27.amzn2023.0.2.src.rpm
Repository   : amazonlinux
Summary      : Library and utilities to manage a Ruby application's gem dependencies
URL          : https://www.ruby-lang.org/
License      : MIT AND (Ruby OR BSD-2-Clause)
Description  : Bundler manages an application's dependencies through its entire life, across
             : many machines, systematically and repeatably.
bash-5.2# dnf install -qy ruby3.4

Installed:
  ruby3.4-3.4.8-27.amzn2023.0.2.aarch64                                           ruby3.4-default-gems-3.4.8-27.amzn2023.0.2.noarch
  ruby3.4-libs-3.4.8-27.amzn2023.0.2.aarch64                                      ruby3.4-rubygem-bigdecimal-3.1.8-27.amzn2023.0.2.aarch64
  ruby3.4-rubygem-bundler-2.6.9-27.amzn2023.0.2.noarch                            ruby3.4-rubygem-io-console-0.8.1-27.amzn2023.0.2.aarch64
  ruby3.4-rubygem-json-2.9.1-27.amzn2023.0.2.aarch64                              ruby3.4-rubygem-psych-5.2.2-27.amzn2023.0.2.aarch64
  ruby3.4-rubygem-rdoc-6.14.0-27.amzn2023.0.2.noarch                              ruby3.4-rubygems-3.6.9-27.amzn2023.0.2.noarch

bash-5.2# ls /usr/bin/bundle
ls: cannot access '/usr/bin/bundle': No such file or directory

bash-5.2# ls /usr/bin/
'['	      comm	  false			 groups      mktemp		  python3	    ruby3.4-ri		     sync       update-ca-trust
 alias	      command	  fc			 gsettings   modulemd-validator   python3.9	    ruby3.4-syntax_suggest   tac        users
 arch	      coreutils   fg			 hash	     mv			  read		    runcon		     tail       vdir
 awk	      cp	  fgrep			 head	     nice		  readlink	    sed			     tee        wait
 b2sum	      csplit	  fmt			 hostid      nl			  realpath	    seq			     test       wc
 base32       curl	  fold			 iconv	     nohup		  rm		    sh			     timeout    wcurl
 base64       cut	  gapplication		 id	     nproc		  rmdir		    sha1sum		     touch      who
 basename     date	  gawk			 install     numfmt		  rpm		    sha224sum		     tr         whoami
 basenc       dd	  gdbus			 jobs	     od			  rpm2archive	    sha256sum		     true       xmlcatalog
 bash	      df	  gencat		 join	     p11-kit		  rpm2cpio	    sha384sum		     truncate   xmllint
 bashbug      dir	  getconf		 ld.so	     paste		  rpmdb		    sha512sum		     trust      xmlwf
 bashbug-64   dircolors   getent		 ldd	     pathchk		  rpmkeys	    shred		     tsort      yes
 bg	      dirname	  getopts		 link	     pinky		  rpmquery	    shuf		     tty        yum
 ca-legacy    dnf	  gio			 ln	     pldd		  rpmverify	    sleep		     type       zdump
 cat	      dnf-3	  gio-querymodules-64	 locale      pr			  ruby		    sort		     tzselect
 catchsegv    du	  glib-compile-schemas	 localedef   printenv		  ruby3.4	    sotruss		     ulimit
 cd	      echo	  gpg			 logname     printf		  ruby3.4-bundle    split		     umask
 chcon	      egrep	  gpg-error		 ls	     ptx		  ruby3.4-bundler   sprof		     unalias
 chgrp	      env	  gpg2			 md5sum      pwd		  ruby3.4-erb	    stat		     uname
 chmod	      expand	  gpgme-json		 mkdir	     pydoc		  ruby3.4-gem	    stdbuf		     unexpand
 chown	      expr	  gpgv2			 mkfifo      pydoc3		  ruby3.4-mri	    stty		     uniq
 cksum	      factor	  grep			 mknod	     pydoc3.9		  ruby3.4-rdoc	    sum			     unlink

Expected behavior

Commands without the ruby3.4- prefix are also created.

Screenshots
NONE

Additional context

bash-5.2# alternatives --display ruby
ruby - status is auto.
 link currently points to /usr/bin/ruby3.4-mri
/usr/bin/ruby3.4-mri - priority 34
 slave ruby.1.gz: /usr/share/man/man1/ruby3.4.1.gz
Current `best' version is /usr/bin/ruby3.4-mri.

bash-5.2# rpm -q --scripts ruby3.4-rubygem-bundler
posttrans scriptlet (using /bin/sh):
[ -L /usr/bin/bundle ] || /usr/bin/rm -f /usr/bin/bundle
/usr/sbin/alternatives --add-slave ruby /usr/bin/ruby3.4  \
  /usr/bin/bundle bundle /usr/bin/ruby3.4-bundle || :
[ -L /usr/bin/bundler ] || /usr/bin/rm -f /usr/bin/bundler
/usr/sbin/alternatives --add-slave ruby /usr/bin/ruby3.4  \
  /usr/bin/bundler bundler /usr/bin/ruby3.4-bundler || :
[ -L /usr/share/man/man1/bundle.1.gz ] || /usr/bin/rm -f /usr/share/man/man1/bundle.1.gz
/usr/sbin/alternatives --add-slave ruby /usr/bin/ruby3.4 \
    /usr/share/man/man1/bundle.1.gz bundle.1.gz \
    /usr/share/man/man1/ruby3.4-bundle.1.gz || :
[ -L /usr/share/man/man5/gemfile.5.gz ] || /usr/bin/rm -f /usr/share/man/man5/gemfile.5.gz
/usr/sbin/alternatives --add-slave ruby /usr/bin/ruby3.4 \
    /usr/share/man/man5/gemfile.5.gz gemfile.5.gz \
    /usr/share/man/man5/ruby3.4-gemfile.5.gz || :
for f in add binstubs cache check clean config console doctor exec gem help \
  info init inject install list lock open outdated platform plugin pristine \
  remove show update version viz; do
    [ -L /usr/share/man/man1/bundle-${f}.1.gz ] || /usr/bin/rm -f /usr/share/man/man1/bundle-${f}.1.gz
    /usr/sbin/alternatives --add-slave ruby /usr/bin/ruby3.4 \
      /usr/share/man/man1/bundle-${f}.1.gz bundle-${f}.1.gz \
      /usr/share/man/man1/ruby3.4-bundle-${f}.1.gz || :
done
bash-5.2# alternatives --install /usr/bin/ruby ruby /usr/bin/ruby3.4 34
bash-5.2# alternatives --set ruby /usr/bin/ruby3.4
bash-5.2# dnf reinstall -qy ruby3.4-rubygem-bundler

Reinstalled:
  ruby3.4-rubygem-bundler-2.6.9-27.amzn2023.0.2.noarch

bash-5.2# ls /usr/bin/bundle*
/usr/bin/bundle  /usr/bin/bundler
bash-5.2# bundle -v
/usr/share/gems/ruby3.4/rubygems.rb:269:in 'Gem.find_spec_for_exe': can't find gem bundler (>= 0.a) with executable bundle (Gem::GemNotFoundException)
	from /usr/share/gems/ruby3.4/rubygems.rb:288:in 'Gem.activate_bin_path'
	from /usr/bin/bundle:25:in '<main>'

bash-5.2# GEM_PATH=/usr/share/gems/ruby3.4 bundle -v
Ignoring io-console-0.8.1 because its extensions are not built. Try: gem pristine io-console --version 0.8.1
Ignoring psych-5.2.2 because its extensions are not built. Try: gem pristine psych --version 5.2.2
Bundler version 2.6.9

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions