build: pass env vars as build args to fix localhost:8000 error
Some checks failed
Build and Deploy / build (push) Failing after 0s

- Add ARG and ENV directives to Dockerfile for NEXT_PUBLIC_* vars
- Pass build args in buildctl command with --opt build-arg
- Fixes ERR_BLOCKED_BY_CLIENT on localhost:8000/graphql
This commit is contained in:
Unchained
2026-04-05 11:24:01 +02:00
parent 80da03504c
commit d53665d6da
2 changed files with 18 additions and 6 deletions

View File

@@ -54,8 +54,13 @@ jobs:
--frontend dockerfile.v0 \
--local context=/workspace \
--local dockerfile=/workspace \
--opt build-arg:NEXT_PUBLIC_SALEOR_API_URL=https://api.manoonoils.com/graphql/ \
--opt build-arg:NEXT_PUBLIC_SITE_URL=https://manoonoils.com \
--opt build-arg:NEXT_PUBLIC_OPENPANEL_CLIENT_ID=fa61f8ae-0b5d-4187-a9b1-5a04b0025674 \
--opt build-arg:NEXT_PUBLIC_RYBBIT_HOST=https://rybbit.nodecrew.me \
--opt build-arg:NEXT_PUBLIC_RYBBIT_SITE_ID=1 \
--output type=image,name=ghcr.io/unchainedio/manoon-headless:latest,push=true
kubectl annotate kustomization -n flux-system manoonoils-storefront --overwrite reconcile.fluxcd.io/requestedAt="\1775369769"
kubectl annotate kustomization -n flux-system manoonoils-storefront --overwrite reconcile.fluxcd.io/requestedAt="$(date +%s)"
echo "Done!"
volumeMounts:
- name: workspace