Add `-exo pipefail` and update ruby version