Compare commits
4 Commits
2c11b5026a
...
v1.2.11
| Author | SHA1 | Date | |
|---|---|---|---|
| b10dbcb23f | |||
| 65bb9c620a | |||
| 63853ffa89 | |||
| 9694c77ef7 |
@@ -50,12 +50,15 @@ jobs:
|
|||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: .turbo
|
path: .turbo
|
||||||
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
key: ${{ runner.os }}-turbo-${{ github.ref_name }}-${{ github.sha }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
|
${{ runner.os }}-turbo-${{ github.ref_name }}-
|
||||||
${{ runner.os }}-turbo-
|
${{ runner.os }}-turbo-
|
||||||
|
|
||||||
- name: 🧪 QA Checks
|
- name: 🧪 QA Checks
|
||||||
run: npx turbo run check:mdx lint typecheck test
|
env:
|
||||||
|
TURBO_TELEMETRY_DISABLED: "1"
|
||||||
|
run: npx turbo run check:mdx lint typecheck test --cache-dir=".turbo"
|
||||||
|
|
||||||
- name: 🏗️ Build
|
- name: 🏗️ Build
|
||||||
run: pnpm build
|
run: pnpm build
|
||||||
|
|||||||
@@ -175,15 +175,18 @@ jobs:
|
|||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: .turbo
|
path: .turbo
|
||||||
key: ${{ runner.os }}-turbo-${{ github.sha }}
|
key: ${{ runner.os }}-turbo-${{ github.ref_name }}-${{ github.sha }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
|
${{ runner.os }}-turbo-${{ github.ref_name }}-
|
||||||
${{ runner.os }}-turbo-
|
${{ runner.os }}-turbo-
|
||||||
|
|
||||||
- name: 🔒 Security Audit
|
- name: 🔒 Security Audit
|
||||||
run: pnpm audit --audit-level high
|
run: pnpm audit --audit-level high
|
||||||
- name: 🧪 QA Checks
|
- name: 🧪 QA Checks
|
||||||
if: github.event.inputs.skip_checks != 'true'
|
if: github.event.inputs.skip_checks != 'true'
|
||||||
run: npx turbo run lint check:spell typecheck test
|
env:
|
||||||
|
TURBO_TELEMETRY_DISABLED: "1"
|
||||||
|
run: npx turbo run lint check:spell typecheck test --cache-dir=".turbo"
|
||||||
|
|
||||||
# ──────────────────────────────────────────────────────────────────────────────
|
# ──────────────────────────────────────────────────────────────────────────────
|
||||||
# JOB 3: Build & Push
|
# JOB 3: Build & Push
|
||||||
@@ -209,6 +212,8 @@ jobs:
|
|||||||
push: true
|
push: true
|
||||||
provenance: false
|
provenance: false
|
||||||
platforms: linux/arm64
|
platforms: linux/arm64
|
||||||
|
cache-from: type=gha,scope=nextjs-build-${{ needs.prepare.outputs.target }}
|
||||||
|
cache-to: type=gha,mode=max,scope=nextjs-build-${{ needs.prepare.outputs.target }}
|
||||||
build-args: |
|
build-args: |
|
||||||
NEXT_PUBLIC_BASE_URL=${{ needs.prepare.outputs.next_public_url }}
|
NEXT_PUBLIC_BASE_URL=${{ needs.prepare.outputs.next_public_url }}
|
||||||
NEXT_PUBLIC_TARGET=${{ needs.prepare.outputs.target }}
|
NEXT_PUBLIC_TARGET=${{ needs.prepare.outputs.target }}
|
||||||
|
|||||||
@@ -41,7 +41,10 @@ CMD ["pnpm", "dev:local"]
|
|||||||
# Build application
|
# Build application
|
||||||
# Stage 3: Builder (Production)
|
# Stage 3: Builder (Production)
|
||||||
FROM base AS builder
|
FROM base AS builder
|
||||||
RUN pnpm build
|
RUN --mount=type=cache,target=/app/.next/cache,id=nextjs-cache \
|
||||||
|
pnpm build && \
|
||||||
|
mkdir -p /app/.next-cache-tmp && \
|
||||||
|
cp -r /app/.next/cache/* /app/.next-cache-tmp/ || true
|
||||||
|
|
||||||
# Stage 3: Runner
|
# Stage 3: Runner
|
||||||
FROM registry.infra.mintel.me/mintel/runtime:v1.7.10 AS runner
|
FROM registry.infra.mintel.me/mintel/runtime:v1.7.10 AS runner
|
||||||
@@ -60,6 +63,6 @@ ENV NODE_ENV=production
|
|||||||
COPY --from=builder --chown=nextjs:nodejs /app/public ./public
|
COPY --from=builder --chown=nextjs:nodejs /app/public ./public
|
||||||
COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./
|
COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./
|
||||||
COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
|
COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
|
||||||
COPY --from=builder --chown=nextjs:nodejs /app/.next/cache ./.next/cache
|
COPY --from=builder --chown=nextjs:nodejs /app/.next-cache-tmp ./.next/cache
|
||||||
|
|
||||||
CMD ["node", "server.js"]
|
CMD ["node", "server.js"]
|
||||||
|
|||||||
@@ -166,8 +166,8 @@ services:
|
|||||||
- "host.docker.internal:host-gateway"
|
- "host.docker.internal:host-gateway"
|
||||||
environment:
|
environment:
|
||||||
OPENROUTER_API_KEY: ${OPENROUTER_API_KEY}
|
OPENROUTER_API_KEY: ${OPENROUTER_API_KEY}
|
||||||
# IMGPROXY_URL_MAPPING is not used by our new service yet, but we can keep it for future parity if we add it back
|
# explicitly map localhost, production and staging to bypass gatekeeper
|
||||||
IMGPROXY_URL_MAPPING: "${NEXT_PUBLIC_BASE_URL}:http://klz-app:3000,${DIRECTUS_URL}:http://klz-cms:8055"
|
IMGPROXY_URL_MAPPING: "https://staging.klz-cables.com:http://klz-app:3000,https://klz-cables.com:http://klz-app:3000,https://${TRAEFIK_HOST:-klz.localhost}:http://klz-app:3000,${DIRECTUS_URL}:http://klz-cms:8055,https://cms.klz-cables.com:http://klz-cms:8055"
|
||||||
IMGPROXY_LOG_LEVEL: debug
|
IMGPROXY_LOG_LEVEL: debug
|
||||||
|
|
||||||
labels:
|
labels:
|
||||||
|
|||||||
@@ -126,7 +126,7 @@
|
|||||||
"prepare": "husky",
|
"prepare": "husky",
|
||||||
"preinstall": "npx only-allow pnpm"
|
"preinstall": "npx only-allow pnpm"
|
||||||
},
|
},
|
||||||
"version": "1.0.0",
|
"version": "1.0.1-rc.0",
|
||||||
"pnpm": {
|
"pnpm": {
|
||||||
"overrides": {
|
"overrides": {
|
||||||
"next": "16.1.6",
|
"next": "16.1.6",
|
||||||
|
|||||||
Reference in New Issue
Block a user