Skip to content

Connect GitHub repo to Vercel for automatic production deploys #20

Description

@Cbiux

Summary

Connect Zcorehub/ZCore-dev to Vercel for automatic deploys on push to main — replace manual vercel --prod CLI deploys.


Current state

  • Manual deploy works (vercel --prod from Server/ and Front/)
  • Two Vercel projects: zcore-api (root Server/) and dapp-zcore (root Front/)
  • Production URLs: https://zcore-api.vercel.app, https://zcore-xi.vercel.app

Steps

1. Link GitHub repo (both projects)

Vercel Dashboard → Project → Settings → Git:

Project Root directory Production branch
zcore-api Server main
dapp-zcore Front main

Enable preview deployments for PRs.

2. Confirm build settings

Server (Server/vercel.json):

  • Install: npm install
  • Build: npx prisma generate && npm run build

Front (Front/vercel.json):

  • Install: npm install --legacy-peer-deps
  • Framework: Next.js

3. Sync env vars

Production env must include at minimum (see #15):

  • DATABASE_URL, JWT_SECRET, ADMIN_SECRET, STELLAR_NETWORK
  • Front: NEXT_PUBLIC_API_BASE_URL, NEXT_PUBLIC_STELLAR_NETWORK

4. Verify

Push empty commit or merge PR → both projects deploy automatically.

git commit --allow-empty -m "chore: verify Vercel Git integration"
git push origin main

Acceptance criteria

  • Push to main triggers prod deploy for API and dapp
  • PRs get preview URLs
  • No manual CLI deploy needed for routine releases
  • Document in Docs/vercel-deploy.md

Out of scope

  • Staging environment (separate MySQL) — deferred

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    GrantFox OSSPart of the GrantFox OSS programMaybe RewardedThis issue may receive a reward or bountyOfficial CampaignPart of an official ZCore campaignenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions