diff --git a/.gitea/workflows/build-next.yml b/.gitea/workflows/build-next.yml index 9632d43..76694f9 100644 --- a/.gitea/workflows/build-next.yml +++ b/.gitea/workflows/build-next.yml @@ -40,6 +40,10 @@ jobs: - uses: actions/checkout@v4 - name: Log in to container registry run: echo "${{ secrets.REGISTRY_PASSWORD }}" | docker login git.gbrown.org -u "${{ secrets.REGISTRY_USER }}" --password-stdin + - uses: oven-sh/setup-bun@v2 + with: + bun-version: 1.3.10 + - run: bun install --frozen-lockfile - name: Build image env: DOTENV_PROD: ${{ secrets.DOTENV_PROD }} diff --git a/scripts/build-next-app b/scripts/build-next-app index b8ccfb2..65d5dd8 100755 --- a/scripts/build-next-app +++ b/scripts/build-next-app @@ -9,7 +9,7 @@ cleanup() { [[ -n "$ENV_FILE" && "$ENV_FILE" != "${CI_ENV_FILE:-}" ]] && rm -f " trap cleanup EXIT if [[ -z "$ENV_FILE" && -z "${CI:-}" ]]; then ENV_FILE="$(mktemp)"; sh "$ROOT_DIR/scripts/export-env" "$ENVIRONMENT" > "$ENV_FILE"; fi if [[ -n "$ENV_FILE" ]]; then - bunx dotenv -e "$ENV_FILE" -- bash "$ROOT_DIR/scripts/convex-codegen" + bun dotenv -e "$ENV_FILE" -- bash "$ROOT_DIR/scripts/convex-codegen" else bash "$ROOT_DIR/scripts/convex-codegen" fi diff --git a/scripts/update-next-app b/scripts/update-next-app index 525e43c..65b440d 100755 --- a/scripts/update-next-app +++ b/scripts/update-next-app @@ -5,6 +5,6 @@ ENVIRONMENT="${1:-staging}" [[ "$ENVIRONMENT" == dev || "$ENVIRONMENT" == staging ]] || { echo "usage: update-next-app [dev|staging]" >&2; exit 2; } ENV_FILE="$(mktemp)"; trap 'rm -f "$ENV_FILE"' EXIT sh "$ROOT_DIR/scripts/export-env" "$ENVIRONMENT" > "$ENV_FILE" -bunx dotenv -e "$ENV_FILE" -- bash "$ROOT_DIR/scripts/convex-codegen" +bun dotenv -e "$ENV_FILE" -- bash "$ROOT_DIR/scripts/convex-codegen" docker compose --env-file "$ENV_FILE" -f "$ROOT_DIR/docker/compose.yml" build spoon-next docker compose --env-file "$ENV_FILE" -f "$ROOT_DIR/docker/compose.yml" up -d spoon-next