Job failed due to docker image not being in lowercase

I am trying to use a docker image from GitHub packages, which is under docker.pkg.github.com/{repository}/:, but the problem is that the repository owner is an organization which name has an uppercase letter, and docker doesn’t accept image names with uppercase letters.
I’ve tried to convert the repository name into lowercase and storing it in a env var, but .container.image doesn’t have access to env context.

I was wondering if someone encountered this issue and found a solution?
I also thought of trying to define a function to convert an string to lowercase, but it seems it’s not possible.
You can find an example of the issue here: Test only linux · Nordix/geode-native@c80bece · GitHub

The env context is only available in steps, even though it can be set at workflow, job, and step level (also see How to use env context?). There is another way to set a variable of sorts that should do the trick: Setting a job output and then refer to it with ${{ jobs.<job_id>.outputs.<output> }} in another job.

jobs:
  set-output:
    runs-on: ubuntu-latest
    outputs:
      image: ${{ steps.set.outputs.image }}
    steps:
      - name: Set output
        id: set
        shell: bash
        run: |
          name="Alpine"
          echo "::set-output name=image::${name,,}"
  use-output:
    runs-on: ubuntu-latest
    needs: set-output
    container:
      image: ${{ needs.set-output.outputs.image }}
    steps:
      - name: Print Linux OS info
        run: cat /etc/alpine-release

The set-output job runs a bit of Bash code to convert the string Alpine to lowercase and sets it as output. The use-output job depends on the set-output job and uses the output image to set the container.