diff options
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r-- | .gitlab-ci.yml | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2476dd9..0cf08ec 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,10 +1,20 @@ image: "debian:buster-slim" +cache: + key: global + paths: + - .yarn + - node_modules + - data/vicmap.geojson + stages: + - prepare - build -build: - stage: build +prepare: + stage: prepare + cache: + policy: push script: - apt-get update && apt-get install -y curl gnupg gdal-bin unzip wget make - curl -fsSL https://deb.nodesource.com/setup_12.x | bash - @@ -13,9 +23,23 @@ build: - apt-get update && apt-get install -y yarn nodejs - yarn install - mkdir -p dist - - make data/VICMAP_ADDRESS.zip unzip - make data/vicmap.geojson + when: manual + +build: + stage: build + cache: + policy: pull + script: + - apt-get update && apt-get install -y curl gnupg make + - curl -fsSL https://deb.nodesource.com/setup_12.x | bash - + - curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - + - echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list + - apt-get update && apt-get install -y yarn nodejs + - yarn install + - mkdir -p dist - make dist/vicmap-osm.geojson + - make dist/vicmap-osm-flats.geojson artifacts: name: "build" paths: |