Skip to content

Commit

Permalink
Get architecture from within container build
Browse files Browse the repository at this point in the history
  • Loading branch information
julianschuler committed Jun 18, 2024
1 parent 045f201 commit 00514f8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,10 @@ jobs:
with:
image: naosdk
tags: latest ${{ github.sha }} ${{ env.version }}
archs: x86_64
archs: x86_64, aarch64
containerfiles: ./Containerfile
build-args: |
version=${{ env.version }}
arch=x86_64
- name: Push development image to ghcr.io
uses: redhat-actions/push-to-registry@v2
with:
Expand Down
8 changes: 5 additions & 3 deletions Containerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
FROM debian

RUN apt-get update && apt-get install --no-install-recommends --yes \
ca-certificates \
curl \
file \
python3 \
xz-utils \
zstd

ARG version
ARG arch

ADD --chmod=744 https://github.com/HULKs/meta-nao/releases/download/${version}/HULKs-OS-${arch}-toolchain-${version}.sh /opt/toolchain.sh
RUN curl --fail --location --progress-bar --output /opt/toolchain.sh \
https://github.com/HULKs/meta-nao/releases/download/${version}/HULKs-OS-$(uname -m)-toolchain-${version}.sh

RUN /opt/toolchain.sh -d /naosdk -y && rm /opt/toolchain.sh
RUN chmod +x /opt/toolchain.sh && /opt/toolchain.sh -d /naosdk -y && rm /opt/toolchain.sh
RUN echo . /naosdk/environment-setup-corei7-64-aldebaran-linux >> /root/.bashrc

0 comments on commit 00514f8

Please sign in to comment.