Set up Cursor Cloud dev environment (AGENTS.md + startup script)#12
Draft
khakimov wants to merge 1 commit into
Draft
Set up Cursor Cloud dev environment (AGENTS.md + startup script)#12khakimov wants to merge 1 commit into
khakimov wants to merge 1 commit into
Conversation
Co-authored-by: Ruslan <khakimov@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Sets up the development environment for the OpenScan monorepo so the primary
webapp can be run and tested locally, and documents the non-obvious startup steps for future cloud agents.AGENTS.mdwith a## Cursor Cloud specific instructionssection covering: scope, thecontracts→data-opsbuild order gotcha, required first-run setup (apps/web/.dev.vars, local D1 migrations,cf-typegen), how to run the web app, the OAuth-only-UI vs API email/password auth note, and lint/test/typecheck caveats.pnpm install+ build@repo/contracts+ build@repo/data-ops.No application code is modified. The generated
apps/web/worker-configuration.d.ts,apps/web/.dev.vars, and.wrangler/stateare intentionally not committed (generated/gitignored).Environment
.nvmrc).pnpm;@repo/contractsand@repo/data-opscompiled todist/(required before anything that imports them).wrangler d1 migrations apply sec-db --local(no Cloudflare account needed; miniflare-backed).apps/web/.dev.varsprovides localBETTER_AUTH_SECRET/APP_URL/BETTER_AUTH_URL.Hello-world verification
Created a new account, organization, and project end-to-end against the running app + local D1, both via the API and through the real onboarding UI. Verified the rows persisted in D1.
openscan_onboarding_create_org_project.mp4
Creating an organization ("Acme Security") and project ("Corp Web Assets", domain
acme-demo.com) through the onboarding UI, then advancing to the Asset Discovery step.Asset discovery step after creating org + project
Testing
pnpm installpnpm --filter @repo/contracts buildpnpm run build:data-opscd apps/web && pnpm wrangler d1 migrations apply sec-db --localpnpm run dev:web(serves http://localhost:13000;/api/health→ 200)pnpm --filter @repo/data-ops test:run(133 passed; 1 pre-existing failure unrelated to setup)pnpm --filter web typecheck(pre-existing errors: web app lacksvitest/drizzle-ormdev deps for its test files, plus a null-check insrc/trpc/utils/project-access.ts)To show artifacts inline, enable in settings.