Merge pull request #32 from RapidSilicon/upstream
Merge Upstream OpenFPGA
This commit is contained in:
commit
d6749697c5
|
@ -14,6 +14,8 @@ env:
|
||||||
BUILD_TYPE: Release
|
BUILD_TYPE: Release
|
||||||
MAKEFLAGS: "-j8"
|
MAKEFLAGS: "-j8"
|
||||||
DOCKER_REPO: ${{ secrets.DOCKER_REPO }}
|
DOCKER_REPO: ${{ secrets.DOCKER_REPO }}
|
||||||
|
# (Boolean) Setting this value to True, will force linux tet always
|
||||||
|
IGNORE_DOCKER_TEST: ${{ secrets.IGNORE_DOCKER_TEST }}
|
||||||
REPO_OWNER: ${{ github.repository_owner }}
|
REPO_OWNER: ${{ github.repository_owner }}
|
||||||
|
|
||||||
# Multiple job to tests
|
# Multiple job to tests
|
||||||
|
@ -42,8 +44,8 @@ jobs:
|
||||||
else
|
else
|
||||||
echo "::set-output name=status_code::$?"
|
echo "::set-output name=status_code::$?"
|
||||||
fi
|
fi
|
||||||
if [[ ${GITHUB_REF} == 'refs/heads/master' ]]; then
|
if [[ (${GITHUB_REF} == 'refs/heads/master') || -n "${IGNORE_DOCKER_TEST}" ]]; then
|
||||||
echo "Current brnach is master forcing source_modified"
|
echo "Current branch is master forcing source_modified"
|
||||||
echo "::set-output name=status_code::1"
|
echo "::set-output name=status_code::1"
|
||||||
fi
|
fi
|
||||||
if [[ -n "${DOCKER_REPO}" ]]; then
|
if [[ -n "${DOCKER_REPO}" ]]; then
|
||||||
|
|
|
@ -8,13 +8,12 @@ env:
|
||||||
REPO_OWNER: ${{ github.repository_owner }}
|
REPO_OWNER: ${{ github.repository_owner }}
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
base_images:
|
change_detect:
|
||||||
name: Push Docker images
|
name: "Detect code changes"
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-18.04
|
||||||
if: ${{ env.DOCKER_REPO }}
|
outputs:
|
||||||
|
docker_repo: ${{ steps.changes.outputs.docker_repo }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: Check for source code changes
|
- name: Check for source code changes
|
||||||
id: changes
|
id: changes
|
||||||
run: |
|
run: |
|
||||||
|
@ -25,6 +24,14 @@ jobs:
|
||||||
echo "name=docker_repo::lnis-uofu"
|
echo "name=docker_repo::lnis-uofu"
|
||||||
echo "::set-output name=docker_repo::lnis-uofu"
|
echo "::set-output name=docker_repo::lnis-uofu"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
base_images:
|
||||||
|
name: Push Docker images
|
||||||
|
needs: [change_detect]
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
uses: docker/setup-qemu-action@v1
|
uses: docker/setup-qemu-action@v1
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
|
@ -40,18 +47,19 @@ jobs:
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
file: ./docker/Dockerfile.base
|
file: ./docker/Dockerfile.base
|
||||||
push: true
|
push: ${{ (env.DOCKER_REPO) && (github.ref == 'refs/heads/master')}}
|
||||||
tags: ghcr.io/${{ needs.change_detect.outputs.docker_repo }}/openfpga-build-base:latest
|
tags: ghcr.io/${{ needs.change_detect.outputs.docker_repo }}/openfpga-build-base:latest
|
||||||
- name: Build environment image
|
- name: Build environment image
|
||||||
uses: docker/build-push-action@v2
|
uses: docker/build-push-action@v2
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
file: ./docker/Dockerfile.env
|
file: ./docker/Dockerfile.env
|
||||||
push: true
|
push: ${{ (env.DOCKER_REPO) && (github.ref == 'refs/heads/master')}}
|
||||||
tags: ghcr.io/${{ needs.change_detect.outputs.docker_repo }}/openfpga-env:latest
|
tags: ghcr.io/${{ needs.change_detect.outputs.docker_repo }}/openfpga-env:latest
|
||||||
|
|
||||||
compiler_images:
|
compiler_images:
|
||||||
name: Build ${{ matrix.compiler }} compiler image
|
name: Build ${{ matrix.compiler }} compiler image
|
||||||
needs: base_images
|
needs: [base_images, change_detect]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
|
@ -81,5 +89,5 @@ jobs:
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
file: ./docker/Dockerfile.${{ matrix.compiler }}
|
file: ./docker/Dockerfile.${{ matrix.compiler }}
|
||||||
push: true
|
push: ${{ (env.DOCKER_REPO) && (github.ref == 'refs/heads/master')}}
|
||||||
tags: ghcr.io/${{ needs.change_detect.outputs.docker_repo }}/openfpga-build-${{ matrix.compiler }}:latest
|
tags: ghcr.io/${{ needs.change_detect.outputs.docker_repo }}/openfpga-build-${{ matrix.compiler }}:latest
|
||||||
|
|
Loading…
Reference in New Issue