ci: fix convex tmp dir
This commit is contained in:
parent
b707b56ba1
commit
c1ce7f1ab9
1 changed files with 7 additions and 6 deletions
13
.github/workflows/ci-cd-web-desktop.yml
vendored
13
.github/workflows/ci-cd-web-desktop.yml
vendored
|
|
@ -487,21 +487,22 @@ jobs:
|
||||||
-e MACHINE_PROVISIONING_SECRET \
|
-e MACHINE_PROVISIONING_SECRET \
|
||||||
-e MACHINE_TOKEN_TTL_MS \
|
-e MACHINE_TOKEN_TTL_MS \
|
||||||
-e FLEET_SYNC_SECRET \
|
-e FLEET_SYNC_SECRET \
|
||||||
-e CONVEX_TMPDIR=/app/convex/_generated/tmp \
|
-e CONVEX_TMPDIR=/app/.convex-tmp \
|
||||||
node:20-bullseye bash -lc "set -euo pipefail; curl -fsSL https://bun.sh/install | bash >/tmp/bun-install.log; export BUN_INSTALL=\"\${BUN_INSTALL:-/root/.bun}\"; export PATH=\"\$BUN_INSTALL/bin:\$PATH\"; export CONVEX_TMPDIR=/app/convex/_generated/tmp; bun install --frozen-lockfile; \
|
node:20-bullseye bash -lc "set -euo pipefail; curl -fsSL https://bun.sh/install | bash >/tmp/bun-install.log; export BUN_INSTALL=\"\${BUN_INSTALL:-/root/.bun}\"; export PATH=\"\$BUN_INSTALL/bin:\$PATH\"; export CONVEX_TMPDIR=/app/.convex-tmp; bun install --frozen-lockfile; \
|
||||||
if [ -n \"$MACHINE_PROVISIONING_SECRET\" ]; then bunx convex env set MACHINE_PROVISIONING_SECRET \"$MACHINE_PROVISIONING_SECRET\"; fi; \
|
if [ -n \"$MACHINE_PROVISIONING_SECRET\" ]; then bunx convex env set MACHINE_PROVISIONING_SECRET \"$MACHINE_PROVISIONING_SECRET\"; fi; \
|
||||||
if [ -n \"$MACHINE_TOKEN_TTL_MS\" ]; then bunx convex env set MACHINE_TOKEN_TTL_MS \"$MACHINE_TOKEN_TTL_MS\"; fi; \
|
if [ -n \"$MACHINE_TOKEN_TTL_MS\" ]; then bunx convex env set MACHINE_TOKEN_TTL_MS \"$MACHINE_TOKEN_TTL_MS\"; fi; \
|
||||||
if [ -n \"$FLEET_SYNC_SECRET\" ]; then bunx convex env set FLEET_SYNC_SECRET \"$FLEET_SYNC_SECRET\"; fi; \
|
if [ -n \"$FLEET_SYNC_SECRET\" ]; then bunx convex env set FLEET_SYNC_SECRET \"$FLEET_SYNC_SECRET\"; fi; \
|
||||||
bunx convex env list"
|
bunx convex env list"
|
||||||
|
|
||||||
- name: Ensure .env is not present for Convex deploy
|
- name: Prepare Convex deploy workspace
|
||||||
run: |
|
run: |
|
||||||
cd "$EFFECTIVE_APP_DIR"
|
cd "$EFFECTIVE_APP_DIR"
|
||||||
if [ -f .env ]; then
|
if [ -f .env ]; then
|
||||||
echo "Renaming .env -> .env.bak (Convex self-hosted deploy)"
|
echo "Renaming .env -> .env.bak (Convex self-hosted deploy)"
|
||||||
mv -f .env .env.bak
|
mv -f .env .env.bak
|
||||||
fi
|
fi
|
||||||
mkdir -p convex/_generated/tmp
|
# Dedicated tmp dir outside convex/_generated so CLI cleanups don't remove it
|
||||||
|
mkdir -p .convex-tmp
|
||||||
- name: Deploy functions to Convex self-hosted
|
- name: Deploy functions to Convex self-hosted
|
||||||
env:
|
env:
|
||||||
CONVEX_SELF_HOSTED_URL: https://convex.esdrasrenan.com.br
|
CONVEX_SELF_HOSTED_URL: https://convex.esdrasrenan.com.br
|
||||||
|
|
@ -513,8 +514,8 @@ jobs:
|
||||||
-e CI=true \
|
-e CI=true \
|
||||||
-e CONVEX_SELF_HOSTED_URL \
|
-e CONVEX_SELF_HOSTED_URL \
|
||||||
-e CONVEX_SELF_HOSTED_ADMIN_KEY \
|
-e CONVEX_SELF_HOSTED_ADMIN_KEY \
|
||||||
-e CONVEX_TMPDIR=/app/convex/_generated/tmp \
|
-e CONVEX_TMPDIR=/app/.convex-tmp \
|
||||||
node:20-bullseye bash -lc "set -euo pipefail; curl -fsSL https://bun.sh/install | bash >/tmp/bun-install.log; export BUN_INSTALL=\"\${BUN_INSTALL:-/root/.bun}\"; export PATH=\"\$BUN_INSTALL/bin:\$PATH\"; export CONVEX_TMPDIR=/app/convex/_generated/tmp; bun install --frozen-lockfile; bunx convex deploy"
|
node:20-bullseye bash -lc "set -euo pipefail; curl -fsSL https://bun.sh/install | bash >/tmp/bun-install.log; export BUN_INSTALL=\"\${BUN_INSTALL:-/root/.bun}\"; export PATH=\"\$BUN_INSTALL/bin:\$PATH\"; export CONVEX_TMPDIR=/app/.convex-tmp; bun install --frozen-lockfile; bunx convex deploy"
|
||||||
|
|
||||||
- name: Cleanup old convex build workdirs (keep last 2)
|
- name: Cleanup old convex build workdirs (keep last 2)
|
||||||
run: |
|
run: |
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue