Skip to content

Commit

Permalink
feat: add arm64 architecture (#54)
Browse files Browse the repository at this point in the history
* Handle arm64

* Use arm64 s6 overlay, remove distr-upgrade and clear cache after apt install

* Added linux/arm64 as platform
  • Loading branch information
andersthorsen authored Mar 21, 2021
1 parent 8968bbb commit add46b6
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm/v6,linux/arm/v7
platforms: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
push: false
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
Expand Down Expand Up @@ -89,7 +89,7 @@ jobs:
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm/v6,linux/arm/v7
platforms: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
push: true
tags: ${{ steps.tags.outputs.tags }}
cache-from: type=local,src=/tmp/.buildx-cache
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pull-request-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm/v6,linux/arm/v7
platforms: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
push: false
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
Expand Down Expand Up @@ -104,8 +104,8 @@ jobs:
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm/v6,linux/arm/v7
platforms: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
push: true
tags: ${{ steps.tags.outputs.tags }}
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
4 changes: 2 additions & 2 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm/v6,linux/arm/v7
platforms: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
push: false
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
10 changes: 10 additions & 0 deletions build/fr24feed.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,15 @@ case $arch in
url=https://repo-feed.flightradar24.com/rpi_binaries/fr24feed_${FR24FEED_ARMHF_VERSION}_armhf.tgz # force version 1.0.25-3 because of broken version for rpi
dirname=fr24feed_armhf
;;
arm64)
url=https://repo-feed.flightradar24.com/rpi_binaries/fr24feed_${FR24FEED_ARMHF_VERSION}_armhf.tgz # force version 1.0.25-3 because of broken version for rpi
dirname=fr24feed_armhf
dpkg --add-architecture armhf
apt update
apt install libc6:armhf libstdc++6:armhf libusb-1.0-0:armhf
ldconfig
rm -rf /var/lib/apt/lists/*
;;
armel)
url=https://repo-feed.flightradar24.com/rpi_binaries/fr24feed_${FR24FEED_ARMEL_VERSION}_armhf.tgz # force version 1.0.25-3 because of broken version for rpi
dirname=fr24feed_armhf
Expand All @@ -18,6 +27,7 @@ case $arch in
;;
esac

echo 'downloading for $arch - $url'
mkdir /fr24feed && \
wget -O /fr24feed/fr24feed.tgz $url && \
cd /fr24feed && \
Expand Down
3 changes: 3 additions & 0 deletions build/s6-overlay.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ case $arch in
armhf)
url=https://github.com/just-containers/s6-overlay/releases/download/${S6_OVERLAY_VERSION}/s6-overlay-armhf.tar.gz
;;
arm64)
url=https://github.com/just-containers/s6-overlay/releases/download/${S6_OVERLAY_VERSION}/s6-overlay-aarch64.tar.gz
;;
armel)
url=https://github.com/just-containers/s6-overlay/releases/download/${S6_OVERLAY_VERSION}/s6-overlay-arm.tar.gz
;;
Expand Down

0 comments on commit add46b6

Please sign in to comment.