From 7e95c65bf7fd6d74e6a34792c02cef6df362117c Mon Sep 17 00:00:00 2001 From: Vincent Fazio Date: Mon, 22 Jul 2024 10:24:40 +1000 Subject: [PATCH] Create build-models.yml --- .github/workflows/build-models.yml | 53 ++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 .github/workflows/build-models.yml diff --git a/.github/workflows/build-models.yml b/.github/workflows/build-models.yml new file mode 100644 index 0000000..2901536 --- /dev/null +++ b/.github/workflows/build-models.yml @@ -0,0 +1,53 @@ +# This workflow will install Python dependencies, run tests and lint with a single version of Python +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python + +name: Build Models + +on: + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] + +permissions: + contents: read + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - name: Set up Python 3.10 + uses: actions/setup-python@v3 + with: + python-version: "3.10" + - name: Install COLLADA2GLTF + run: | + mkdir COLLADA2GLTF + pushd COLLADA2GLTF + wget https://github.com/KhronosGroup/COLLADA2GLTF/releases/download/v2.1.5/COLLADA2GLTF-v2.1.5-linux.zip + unzip COLLADA2GLTF-v2.1.5-linux.zip + export COLLADA2GLTF_BIN=`pwd` + popd + - name: Install model sources + mkdir MODEL_SRC + pushd MODEL_SRC + wget https://github.com/AuScope/geomodel-2-3dweb/releases/download/PORTAL_RELEASE_20210718/GEOMODELS_SRC-GA.tar.gz + tar xvfz GEOMODELS_SRC-GA.tar.gz + - name: Install pdm + run: | + python -m pip install --upgrade pip + pip install pdm + - name: Install dependencies + run: | + pdm install + - name: Build + run: | + export GEOMODELS_HOME=`pwd`/MODEL_SRC/GA + echo "GEOMODELS_HOME=$GEOMODELS_HOME" + eval $(pdm venv activate) + cd web_build/ + ./batch_proc.py +