merge in arm64 QEMU build
This commit is contained in:
parent
a1af3631ca
commit
ad9ddc5d30
3 changed files with 7 additions and 152 deletions
109
.github/workflows/Build_Test_Release.yml
vendored
109
.github/workflows/Build_Test_Release.yml
vendored
|
|
@ -1,109 +0,0 @@
|
|||
name: "Build, Test, Publish"
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
docker_user:
|
||||
description: 'Docker Username'
|
||||
required: true
|
||||
docker_token:
|
||||
description: 'Docker Token'
|
||||
required: true
|
||||
npm_token:
|
||||
description: 'NPM Token'
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
release:
|
||||
name: "Build, Test, Publish"
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
-
|
||||
name: "Checkout source code"
|
||||
uses: "actions/checkout@v3.1.0"
|
||||
with:
|
||||
ref: ${{ github.ref }}
|
||||
-
|
||||
name: Set up node
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: '16'
|
||||
-
|
||||
name: Get version
|
||||
run: |
|
||||
echo "PACKAGE_VERSION=$(grep '"version"' package.json | cut -d '"' -f 4 | head -n 1)" >> $GITHUB_ENV
|
||||
-
|
||||
name: Update packages
|
||||
run: sudo apt update -qq
|
||||
-
|
||||
name: Install apt packages
|
||||
run: sudo apt-get install -y libcairo2-dev libjpeg8-dev libpango1.0-dev libgif-dev build-essential g++ xvfb libgles2-mesa-dev libgbm-dev libxxf86vm-dev
|
||||
-
|
||||
name: Install node dependencies
|
||||
run: npm install
|
||||
-
|
||||
name: Download test data
|
||||
run: wget -O test_data.zip https://github.com/maptiler/tileserver-gl/releases/download/v1.3.0/test_data.zip
|
||||
-
|
||||
name: Unzip test data
|
||||
run: unzip -q test_data.zip -d test_data
|
||||
-
|
||||
name: Run tests
|
||||
run: xvfb-run --server-args="-screen 0 1024x768x24" npm test
|
||||
-
|
||||
name: Remove Test Data
|
||||
run: rm -R test_data*
|
||||
-
|
||||
name: Publish to Full Version NPM
|
||||
run: |
|
||||
npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN}
|
||||
npm publish --access public
|
||||
env:
|
||||
NPM_TOKEN: ${{ github.event.inputs.npm_token }}
|
||||
-
|
||||
name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
with:
|
||||
platforms: 'arm64'
|
||||
-
|
||||
name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
-
|
||||
name: Login to DockerHub
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
username: ${{ github.event.inputs.docker_user }}
|
||||
password: ${{ github.event.inputs.docker_token }}
|
||||
-
|
||||
name: Build and publish Full Version to Docker Hub
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: maptiler/tileserver-gl:latest, maptiler/tileserver-gl:${{ env.PACKAGE_VERSION }}
|
||||
platforms: linux/arm64,linux/amd64
|
||||
-
|
||||
name: Create Tileserver Light Directory
|
||||
run: node publish.js --no-publish
|
||||
-
|
||||
name: Install node dependencies
|
||||
run: npm install
|
||||
working-directory: ./light
|
||||
-
|
||||
name: Publish to Light Version NPM
|
||||
working-directory: ./light
|
||||
run: |
|
||||
npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN}
|
||||
npm publish --access public
|
||||
env:
|
||||
NPM_TOKEN: ${{ github.event.inputs.npm_token }}
|
||||
-
|
||||
name: Build and publish Light Version to Docker Hub
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: ./light
|
||||
file: ./light/Dockerfile
|
||||
push: true
|
||||
tags: maptiler/tileserver-gl-light:latest, maptiler/tileserver-gl-light:${{ env.PACKAGE_VERSION }}
|
||||
platforms: linux/arm64,linux/amd64
|
||||
41
.github/workflows/Test.yml
vendored
41
.github/workflows/Test.yml
vendored
|
|
@ -1,41 +0,0 @@
|
|||
name: "Test"
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
release:
|
||||
name: "Test ${{ github.ref }}"
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
-
|
||||
name: "Checkout source code"
|
||||
uses: "actions/checkout@v3.1.0"
|
||||
with:
|
||||
ref: ${{ github.ref }}
|
||||
-
|
||||
name: Set up node
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: '16'
|
||||
-
|
||||
name: Update packages
|
||||
run: sudo apt update -qq
|
||||
-
|
||||
name: Install apt packages
|
||||
run: sudo apt-get install -y libcairo2-dev libjpeg8-dev libpango1.0-dev libgif-dev build-essential g++ xvfb libgles2-mesa-dev libgbm-dev libxxf86vm-dev
|
||||
-
|
||||
name: Install node dependencies
|
||||
run: npm install
|
||||
-
|
||||
name: Download test data
|
||||
run: wget -O test_data.zip https://github.com/maptiler/tileserver-gl/releases/download/v1.3.0/test_data.zip
|
||||
-
|
||||
name: Unzip test data
|
||||
run: unzip -q test_data.zip -d test_data
|
||||
-
|
||||
name: Run tests
|
||||
run: xvfb-run --server-args="-screen 0 1024x768x24" npm test
|
||||
9
.github/workflows/release.yml
vendored
9
.github/workflows/release.yml
vendored
|
|
@ -61,6 +61,11 @@ jobs:
|
|||
env:
|
||||
NPM_TOKEN: ${{ github.event.inputs.npm_token }}
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
with:
|
||||
platforms: 'arm64'
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
|
|
@ -76,7 +81,7 @@ jobs:
|
|||
context: .
|
||||
push: true
|
||||
tags: maptiler/tileserver-gl:latest, maptiler/tileserver-gl:${{ env.PACKAGE_VERSION }}
|
||||
platforms: linux/amd64
|
||||
platforms: linux/arm64,linux/amd64
|
||||
|
||||
- name: Create Tileserver Light Directory
|
||||
run: node publish.js --no-publish
|
||||
|
|
@ -100,4 +105,4 @@ jobs:
|
|||
file: ./light/Dockerfile
|
||||
push: true
|
||||
tags: maptiler/tileserver-gl-light:latest, maptiler/tileserver-gl-light:${{ env.PACKAGE_VERSION }}
|
||||
platforms: linux/amd64
|
||||
platforms: linux/arm64,linux/amd64
|
||||
|
|
|
|||
Loading…
Reference in a new issue