Skip to content

Upgrade from ubuntu18 to ubuntu22 failed #469

Closed as not planned
Closed as not planned

Description

@PavelSusloparov

Ensure the following before filing this issue

  • I verified it reproduces with the latest version with - uses: ruby/setup-ruby@v1 (see Versioning policy)

  • [] I tried to reproduce the issue locally by following the workflow steps (including all commands done by ruby/setup-ruby, except for Downloading Ruby & Extracting Ruby),
    and it did not reproduce locally (if it does reproduce locally, it's not a ruby/setup-ruby issue)

Are you running on a GitHub-hosted runner or a self-hosted runner?

GitHub-hosted runner

The workflow code or a link to the workflow file

- uses: ruby/setup-ruby@v1
  env:
    ImageOS: ubuntu22
  with:
    ruby-version: 3.0.2
    bundler-cache: true


### Link to the log of a failed workflow job, or to a gist with the output

https://gist.github.com/PavelSusloparov/9fc9e328dd17e06751eff1521e8e9340

### The command and output of the failing step

```shell
Run ruby/setup-ruby@v1
/bin/docker exec  1e6d83e0d3886871d7791a6945dd4dd64b228596261ae4c98cfdb84c4b9b19d1 sh -c "cat /etc/*release | grep ^ID"
Modifying PATH
  Entries added to PATH to use selected Ruby:
    /opt/hostedtoolcache/Ruby/3.0.2/x64/bin
Downloading Ruby
  https://github.com/ruby/ruby-builder/releases/download/toolcache/ruby-3.0.2-ubuntu-22.04.tar.gz
  Took   0.87 seconds
Extracting  Ruby
  /bin/tar -xz -C /opt/hostedtoolcache/Ruby/3.0.2 -f /__w/_temp/dec130f4-1643-4745-bea1-e95b68fd6c1b
  Took   0.40 seconds
Print Ruby version
  /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby --version
  /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby)
  /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.35' not found (required by /opt/hostedtoolcache/Ruby/3.0.2/x64/lib/libruby.so.3.0)
  /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (required by /opt/hostedtoolcache/Ruby/3.0.2/x64/lib/libruby.so.3.0)
  /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /opt/hostedtoolcache/Ruby/3.0.2/x64/lib/libruby.so.3.0)
  /opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /opt/hostedtoolcache/Ruby/3.0.2/x64/lib/libruby.so.3.0)
  Took   0.00 seconds
Error: The process '/opt/hostedtoolcache/Ruby/3.0.2/x64/bin/ruby' failed with exit code 1


### Any other notes?

Ubuntu18 support was removed in https://github.com/ruby/setup-ruby yesterday.
I tried to upgrade to ubuntu22, but this failed with the error I provided in above.

Activity

  1. mlyskawinski commented on Feb 28, 2023

    @mlyskawinski

    Having the same issue, please bring back ubuntu -18, as this breaks a lot of pipelines

  2. PavelSusloparov commented on Feb 28, 2023

    @PavelSusloparov
    Author

    Yes please ^^

  3. PavelSusloparov commented on Feb 28, 2023

    @PavelSusloparov
    Author

    ended up stopping using the action in favor of a ruby docker container with the bundle install --frozen step.

  4. MSP-Greg commented on Feb 28, 2023

    @MSP-Greg
    Collaborator

    please bring back ubuntu -18

    That choice is made by GitHub, not by anyone involved in this repo.

    See https://github.com/actions/runner-images

  5. eregon commented on Feb 28, 2023

    @eregon
    Member

    See https://github.com/ruby/setup-ruby/releases/tag/v1.139.0
    macos-10.15 and ubuntu-18.04 are deprecated and have a brownout period every week, so it's no longer possible to reliably build on those platforms with GH runners.
    That means it's not possible to build Ruby binaries on these images reliably, and also jobs on such images fail during the brownout periods and will be completely removed in a month anyway.

    So just change ubuntu-18.04 by ubuntu-20.04 or ubuntu-22.04 or ubuntu-latest.

    You can also stick to v1.138.0, but obviously your workflow will be broken on April 1 then: actions/runner-images#6002.

    If you are not using GitHub-hosted runners then indeed this is unfortunate, but unavoidable as Rubies are built on GitHub-hosted runners.

  6. eregon commented on Feb 28, 2023

    @eregon
    Member

    Ah, I misread, the original report is about something failing on ubuntu-22.04, I'll look at that.

  7. reopened this on Feb 28, 2023
  8. eregon commented on Feb 28, 2023

    @eregon
    Member

    It works fine on GitHub-hosted runners, as proven here:
    https://github.com/eregon/setup-ruby-test/actions/runs/4297309313/jobs/7490118600

    You said you used GitHub-hosted runner but then you set ImageOS: ubuntu22 manually, that doesn't make any sense.
    So either:

    • you use GitHub-hosted runners by specifying runs-on: ubuntu-22.04 and don't specify ImageOS (that's telling this action the incorrect OS, that's pretty evil)
    • you are using a self-hosted runner but your image is not actually based on Ubuntu 22.04.

    Summary: do not set ImageOS, that should be set in the runner, never in the workflow.

  9. eregon commented on Feb 28, 2023

    @eregon
    Member

    I guess I should bring back the code that gets the image version from the OS files, since people seem to misuse ImageOS and don't understand implications of it :(

  10. eregon commented on Mar 3, 2023

    @eregon
    Member

    #473 so ImageOS will be ignored now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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