diff --git a/.github/workflows/build_container.yml b/.github/workflows/build_container.yml index caf40ba..567e22c 100644 --- a/.github/workflows/build_container.yml +++ b/.github/workflows/build_container.yml @@ -25,13 +25,13 @@ jobs: set -x cd container if [ ${{ matrix.host }} = ${{ matrix.target }} ]; then - podman build --build-arg arch=${{ matrix.host }} -f build.containerfile -t ghcr.io/${{ github.repository }}/host-${{ matrix.host }}/target-${{ matrix.target }}:${{ inputs.version }} . + podman build --squash-all --build-arg arch=${{ matrix.host }} -f build.containerfile -t ghcr.io/${{ github.repository }}/host-${{ matrix.host }}/target-${{ matrix.target }}:${{ inputs.version }} . else case ${{ matrix.target }} in amd64) gnu_arch=x86-64 ;; arm64v8) gnu_arch=aarch64 ;; esac - podman build --build-arg native_arch=${{ matrix.host }} --build-arg target_arch=${{ matrix.target }} --build-arg gnu_arch=$gnu_arch -f crossbuild.containerfile -t ghcr.io/${{ github.repository }}/host-${{ matrix.host }}/target-${{ matrix.target }}:${{ inputs.version }} . + podman build --squash-all --build-arg native_arch=${{ matrix.host }} --build-arg target_arch=${{ matrix.target }} --build-arg gnu_arch=$gnu_arch -f crossbuild.containerfile -t ghcr.io/${{ github.repository }}/host-${{ matrix.host }}/target-${{ matrix.target }}:${{ inputs.version }} . fi - name: publish if: ${{ inputs.publish }}