From 79fc1155fd219d19a7a85841df0913c8d967c2b5 Mon Sep 17 00:00:00 2001 From: Sebastian Szeszko Date: Tue, 7 Apr 2026 11:36:37 +0200 Subject: [PATCH] WIP docker build --- .github/workflows/pr-pipeline.yml | 15 +++++++++++++++ Dockerfile | 11 +++++++++++ 2 files changed, 26 insertions(+) create mode 100644 .github/workflows/pr-pipeline.yml diff --git a/.github/workflows/pr-pipeline.yml b/.github/workflows/pr-pipeline.yml new file mode 100644 index 0000000..fb30270 --- /dev/null +++ b/.github/workflows/pr-pipeline.yml @@ -0,0 +1,15 @@ +name: PR pipeline + +on: + pull_request: + branches: + - develop + +jobs: + ci-cd: + uses: HSLdevcom/transitdata-shared-workflows/.github/workflows/ci-cd-typescript.yml@main + with: + checkAndTestInsideDocker: true + checkAndTestOutsideDocker: false + performRelease: false + secrets: inherit diff --git a/Dockerfile b/Dockerfile index 07a41eb..f6c1aba 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,8 @@ +<<<<<<< Updated upstream FROM node:16-bullseye-slim +======= +FROM node:18-bullseye-slim AS base +>>>>>>> Stashed changes ENV WORK=/opt/hsl-map-server ENV DATA_DIR=${WORK}/data @@ -27,6 +31,13 @@ RUN yarn install && yarn cache clean COPY . ${WORK} +# tester stage: run linting checks; exits non-zero if linting fails +FROM base AS tester +RUN yarn eslint . + +# production stage: download map data and expose the server +FROM base AS production + RUN mkdir -p ${DATA_DIR} # OpenMapTiles dataset generated by hsldevcom