Umami is a privacy-first web and product analytics platform. Traffic, campaigns, behavior, conversions, and revenue in one place. No cookies, no surveillance, self-hosted or in the cloud.
TypeScript analyticsaudience-segmentationchartscohort-analysisgoogle-analyticsproduct-analyticsstatisticsuser-journeyweb-analytics
install heatmaps image
Francis Caoe068471f9cec
diff --git a/.github/workflows/cd-cloud.yml b/.github/workflows/cd-cloud.ymlindex 90a09dab0..4e556d80c 100644--- a/.github/workflows/cd-cloud.yml+++ b/.github/workflows/cd-cloud.yml@@ -23,7 +23,7 @@ jobs:with:image: umamisoftware/umamitags: cloud-${{ steps.random_hash.outputs.hash }}, cloud-latest- buildArgs: DATABASE_TYPE=postgresql+ buildArgs: DATABASE_TYPE=postgresql,INSTALL_HEATMAP=trueregistry: docker.iousername: ${{ secrets.DOCKER_USERNAME }}password: ${{ secrets.DOCKER_PASSWORD }}diff --git a/Dockerfile b/Dockerfileindex aaa2e27cb..228e5a367 100644--- a/Dockerfile+++ b/Dockerfile@@ -1,19 +1,23 @@ARG NODE_IMAGE_VERSION="22-alpine"ARG PNPM_VERSION="10.15.1"+ARG INSTALL_HEATMAP="false"# Install dependencies only when neededFROM node:${NODE_IMAGE_VERSION} AS deps+ARG INSTALL_HEATMAP+# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.RUN apk add --no-cache libc6-compatWORKDIR /app+ENV PLAYWRIGHT_BROWSERS_PATH=/ms-playwrightCOPY package.json pnpm-lock.yaml ./RUN npm install -g pnpm-RUN cat > pnpm-workspace.yaml << EOF-strictDepBuilds: false-EOF+RUN printf 'strictDepBuilds: false\n' > pnpm-workspace.yamlRUN pnpm install --frozen-lockfile+RUN mkdir -p $PLAYWRIGHT_BROWSERS_PATH \+ && if [ "$INSTALL_HEATMAP" = "true" ]; then pnpm run install-heatmap; fi# Rebuild the source code only when neededFROM node:${NODE_IMAGE_VERSION} AS builder@@ -39,6 +43,7 @@ ARG NODE_OPTIONSENV NODE_ENV=productionENV NEXT_TELEMETRY_DISABLED=1ENV NODE_OPTIONS=$NODE_OPTIONS+ENV PLAYWRIGHT_BROWSERS_PATH=/ms-playwrightRUN addgroup --system --gid 1001 nodejsRUN adduser --system --uid 1001 nextjs@@ -48,12 +53,7 @@ RUN set -x \RUN echo {} > package.json-RUN cat > pnpm-workspace.yaml << EOF-allowBuilds:- '@prisma/engines': true- prisma: false-verifyDepsBeforeRun: false-EOF+RUN printf "allowBuilds:\n '@prisma/engines': true\n prisma: false\nverifyDepsBeforeRun: false\n" > pnpm-workspace.yaml# Script dependenciesRUN pnpm add npm-run-all dotenv chalk semver \@@ -66,6 +66,7 @@ COPY --from=builder /app/prisma ./prismaCOPY --from=builder /app/prisma.config.ts ./prisma.config.tsCOPY --from=builder /app/scripts ./scriptsCOPY --from=builder /app/generated ./generated+COPY --from=deps --chown=nextjs:nodejs /ms-playwright /ms-playwright# Automatically leverage output traces to reduce image size# https://nextjs.org/docs/advanced-features/output-file-tracing