Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ARM64 processor architecture support #53

Merged
merged 5 commits into from
Jan 6, 2022

Conversation

AlistairB
Copy link
Contributor

@AlistairB AlistairB commented Nov 24, 2021

#1

Superseeds #21

  • Add support for ARM64
    • Install llvm12 on 8.10 + 9.0 for ARM64 as it is required. 9.2 does not require llvm.
  • Improve the pattern used in docker based on other official images to better support multi-architecture.
  • Add hadolint for the dockerfiles.
  • Remove old dockerfiles (they don't serve much purpose and will trigger hadolint failures).

To Do

@AlistairB AlistairB changed the title Testing with travis, to have ARM based CI Trying to get some CI ARM thing going Nov 28, 2021
@AlistairB
Copy link
Contributor Author

AlistairB commented Dec 26, 2021

Saving a record of what I used for the emulated approach before I squash. This failed because dpkg-architecture was still returning x86_64 when emulated.

  emulated:
    timeout-minutes: 30
    runs-on: ubuntu-latest
    name: ${{ matrix.ghc }}-${{ matrix.deb }}
    strategy:
      fail-fast: false
      matrix:
        ghc: ['9.2.1']
        deb: ['buster']
        include:
          # - ghc: '8.10.7'
          #   ghc_minor: '8.10'
          # - ghc: '9.0.1'
          #   ghc_minor: '9.0'
          - ghc: '9.2.1'
            ghc_minor: '9.2'
    steps:
      - uses: actions/checkout@v2
      - uses: actions/checkout@v2
        with:
          repository: docker-library/official-images
          path: official-images
      - name: docker build [${{ matrix.ghc }}]
        uses: uraimo/[email protected]
        with:
          arch: aarch64
          distro: ${{ matrix.deb }}
          githubToken: ${{ github.token }}
          dockerRunArgs: |
            --volume "${PWD}/official-images:/official-images"
          install: |
            apt-get update
            apt-get install -y curl
            curl -fsSL https://get.docker.com | sh
          run: |
            docker build --pull \
              -t haskell:${{ matrix.ghc }}-${{ matrix.deb }} \
              ${{ matrix.ghc_minor }}/${{ matrix.deb }}
            echo 'running official tests'
            ./official-images/test/run.sh haskell:${{ matrix.ghc }}-${{ matrix.deb }}
        uses: nick-invision/retry@v1
        with:
          timeout_minutes: 8
          max_attempts: 3
          command: |
            docker build --pull \
              -t haskell:${{ matrix.ghc }}-${{ matrix.deb }} \
              ${{ matrix.ghc_minor }}/${{ matrix.deb }}
      - uses: actions/checkout@v2
        with:
          repository: docker-library/official-images
          path: official-images
      - name: run official-images tests
        run: ./official-images/test/run.sh haskell:${{ matrix.ghc }}-${{ matrix.deb }}

@AlistairB AlistairB force-pushed the travis-arm branch 6 times, most recently from ca716c6 to 8062b6e Compare December 26, 2021 23:10
@AlistairB AlistairB changed the title Trying to get some CI ARM thing going Add ARM64 processor architecture support Dec 27, 2021
@AlistairB AlistairB force-pushed the travis-arm branch 5 times, most recently from 4553c91 to 4270b8e Compare January 1, 2022 21:50
@AlistairB AlistairB force-pushed the travis-arm branch 6 times, most recently from 00374ed to 7521b1d Compare January 4, 2022 21:11
The current pattern did not work well for this, so the opportunity
was taken to make improvements based on what other popular official
images are doing.
There isn't much point to keeping them around, they out of date and
not the newest pattern. If someone wanted a dockerfile with older versions
they would be better off copying the pattern from the new dockerfiles.

It is convenient to do this now as hadolint has been added to check
the ARM related changes, but these old ones trigger failures.
@AlistairB AlistairB force-pushed the travis-arm branch 3 times, most recently from 2d11e41 to 1bacc50 Compare January 6, 2022 06:20
@AlistairB AlistairB merged commit f7823c8 into haskell:master Jan 6, 2022
@AlistairB AlistairB deleted the travis-arm branch January 6, 2022 06:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant