CI: Only use approved GitHub Actions
This also brings the workflow files inline what is in the os repo Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
This commit is contained in:
parent
a4f240e0e1
commit
c6ee2bf140
76
.github/workflows/build.yml
vendored
76
.github/workflows/build.yml
vendored
@ -85,6 +85,8 @@ jobs:
|
|||||||
ref: ${{ steps.gittargets.outputs.os_ref }}
|
ref: ${{ steps.gittargets.outputs.os_ref }}
|
||||||
path: sources/nuttx
|
path: sources/nuttx
|
||||||
fetch-depth: 1
|
fetch-depth: 1
|
||||||
|
- name: Checkout nuttx repo tags
|
||||||
|
run: git -C sources/nuttx fetch --tags
|
||||||
|
|
||||||
- name: Checkout apps repo
|
- name: Checkout apps repo
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
@ -102,8 +104,8 @@ jobs:
|
|||||||
path: sources/testing
|
path: sources/testing
|
||||||
fetch-depth: 1
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Create Source Bundle
|
- name: Tar sources
|
||||||
run: tar -czf sources.tar.gz sources
|
run: tar zcf sources.tar.gz sources
|
||||||
- name: Archive Source Bundle
|
- name: Archive Source Bundle
|
||||||
uses: actions/upload-artifact@v1
|
uses: actions/upload-artifact@v1
|
||||||
with:
|
with:
|
||||||
@ -125,10 +127,9 @@ jobs:
|
|||||||
uses: actions/download-artifact@v1
|
uses: actions/download-artifact@v1
|
||||||
with:
|
with:
|
||||||
name: source-bundle
|
name: source-bundle
|
||||||
path: ./
|
path: .
|
||||||
- name: Extract Source Artifact
|
- name: Extract sources
|
||||||
run: tar -xf sources.tar.gz
|
run: tar zxf sources.tar.gz
|
||||||
|
|
||||||
- name: Docker Login
|
- name: Docker Login
|
||||||
uses: azure/docker-login@v1
|
uses: azure/docker-login@v1
|
||||||
with:
|
with:
|
||||||
@ -137,32 +138,27 @@ jobs:
|
|||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Docker Pull
|
- name: Docker Pull
|
||||||
uses: nick-invision/retry@v1
|
run: docker pull docker.pkg.github.com/apache/incubator-nuttx-testing/nuttx-ci-linux
|
||||||
with:
|
|
||||||
timeout_minutes: 10
|
|
||||||
max_attempts: 3
|
|
||||||
retry_wait_seconds: 10
|
|
||||||
command: docker pull docker.pkg.github.com/apache/incubator-nuttx-testing/nuttx-ci-linux
|
|
||||||
|
|
||||||
- name: Export NuttX Repo SHA
|
- name: Export NuttX Repo SHA
|
||||||
run: echo "nuttx_sha=`git -C sources/nuttx rev-parse HEAD`" >> $GITHUB_ENV
|
run: echo "nuttx_sha=`git -C sources/nuttx rev-parse HEAD`" >> $GITHUB_ENV
|
||||||
- name: Refresh Git Credentials
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
repository: apache/incubator-nuttx
|
|
||||||
ref: ${{ env.nuttx_sha }}
|
|
||||||
path: sources/nuttx
|
|
||||||
fetch-depth: 1
|
|
||||||
- name: Get Tags for NuttX Repo
|
|
||||||
run: git -C sources/nuttx fetch --tags
|
|
||||||
- name: Run builds
|
- name: Run builds
|
||||||
uses: ./sources/testing/.github/actions/ci-container
|
uses: ./sources/testing/.github/actions/ci-container
|
||||||
env:
|
env:
|
||||||
BLOBDIR: /tools/blobs
|
BLOBDIR: /tools/blobs
|
||||||
with:
|
with:
|
||||||
run: |
|
run: |
|
||||||
|
echo "::add-matcher::sources/nuttx/.github/gcc.json"
|
||||||
|
export CCACHE_DIR=`pwd`/ccache
|
||||||
|
mkdir $CCACHE_DIR
|
||||||
cd sources/testing
|
cd sources/testing
|
||||||
./cibuild.sh testlist/${{matrix.boards}}.dat
|
export ARTIFACTDIR=`pwd`/../../buildartifacts
|
||||||
|
./cibuild.sh -A -c testlist/${{matrix.boards}}.dat
|
||||||
|
ccache -s
|
||||||
|
- uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: linux-builds
|
||||||
|
path: buildartifacts/
|
||||||
|
continue-on-error: true
|
||||||
|
|
||||||
macOS:
|
macOS:
|
||||||
runs-on: macos-10.15
|
runs-on: macos-10.15
|
||||||
@ -175,13 +171,12 @@ jobs:
|
|||||||
uses: actions/download-artifact@v1
|
uses: actions/download-artifact@v1
|
||||||
with:
|
with:
|
||||||
name: source-bundle
|
name: source-bundle
|
||||||
path: ./
|
path: .
|
||||||
- name: Extract Source Artifact
|
- name: Extract sources
|
||||||
run: tar -xf sources.tar.gz
|
run: tar zxf sources.tar.gz
|
||||||
|
|
||||||
- name: Restore Tools Cache
|
- name: Restore Tools Cache
|
||||||
id: cache-tools
|
id: cache-tools
|
||||||
uses: actions/cache@v1
|
uses: actions/cache@v2
|
||||||
env:
|
env:
|
||||||
cache-name: ${{ runner.os }}-cache-tools
|
cache-name: ${{ runner.os }}-cache-tools
|
||||||
with:
|
with:
|
||||||
@ -189,17 +184,18 @@ jobs:
|
|||||||
key: ${{ runner.os }}-tools-${{ hashFiles('./sources/testing/cibuild.sh') }}
|
key: ${{ runner.os }}-tools-${{ hashFiles('./sources/testing/cibuild.sh') }}
|
||||||
|
|
||||||
- name: Export NuttX Repo SHA
|
- name: Export NuttX Repo SHA
|
||||||
run: echo "nuttx_sha=`git -C sources/nuttx rev-parse HEAD`" >> $GITHUB_ENV
|
run: echo "nuttx_sha=`git -C sources/nuttx rev-parse HEAD`" >> $GITHUB_ENV
|
||||||
- name: Refresh Git Credentials
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
repository: apache/incubator-nuttx
|
|
||||||
ref: ${{ env.nuttx_sha }}
|
|
||||||
path: sources/nuttx
|
|
||||||
fetch-depth: 1
|
|
||||||
- name: Get Tags for NuttX Repo
|
|
||||||
run: git -C sources/nuttx fetch --tags
|
|
||||||
- name: Run Builds
|
- name: Run Builds
|
||||||
run: |
|
run: |
|
||||||
|
echo "::add-matcher::sources/nuttx/.github/gcc.json"
|
||||||
|
export CCACHE_DIR=`pwd`/ccache
|
||||||
|
mkdir $CCACHE_DIR
|
||||||
cd sources/testing
|
cd sources/testing
|
||||||
./cibuild.sh -i testlist/${{matrix.boards}}.dat
|
export ARTIFACTDIR=`pwd`/../../buildartifacts
|
||||||
|
./cibuild.sh -i -A -c testlist/${{matrix.boards}}.dat
|
||||||
|
ccache -s
|
||||||
|
- uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: macos-builds
|
||||||
|
path: buildartifacts/
|
||||||
|
continue-on-error: true
|
||||||
|
38
.github/workflows/check.yml
vendored
38
.github/workflows/check.yml
vendored
@ -20,23 +20,25 @@ jobs:
|
|||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout apps repo
|
- name: Checkout nuttx repo
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
path: apps
|
repository: apache/incubator-nuttx
|
||||||
fetch-depth: 0
|
path: nuttx
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: Checkout nuttx repo
|
- name: Checkout apps repo
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
repository: apache/incubator-nuttx
|
repository: apache/incubator-nuttx-apps
|
||||||
path: nuttx
|
path: apps
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: Check Pull Request
|
- name: Check Pull Request
|
||||||
run: |
|
run: |
|
||||||
cd apps
|
echo "::add-matcher::nuttx/.github/nxstyle.json"
|
||||||
commits="${{ github.event.pull_request.base.sha }}..HEAD"
|
cd apps
|
||||||
git log --oneline $commits
|
commits="${{ github.event.pull_request.base.sha }}..HEAD"
|
||||||
echo "../nuttx/tools/checkpatch.sh -g $commits"
|
git log --oneline $commits
|
||||||
../nuttx/tools/checkpatch.sh -g $commits
|
echo "../nuttx/tools/checkpatch.sh -g $commits"
|
||||||
|
../nuttx/tools/checkpatch.sh -g $commits
|
||||||
|
15
.github/workflows/lint.yml
vendored
Normal file
15
.github/workflows/lint.yml
vendored
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
name: ❄️ Lint
|
||||||
|
|
||||||
|
on: [pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
yamllint:
|
||||||
|
name: 🍺 YAML
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: 🧹 YAML Lint
|
||||||
|
uses: github/super-linter@v3
|
||||||
|
env:
|
||||||
|
VALIDATE_YAML: true
|
||||||
|
FILTER_REGEX_INCLUDE: .*\.github/.*
|
Loading…
x
Reference in New Issue
Block a user